Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
hello,
Power bi query very slow.
how to fix?
#"Pridėta rodyklė" = Table.Buffer(Table.AddIndexColumn(#"Filtruotos eilutės5", "Indeksas", 1, 1, Int64.Type)),
#"Pridėtas pasirinktinis1" = Table.AddColumn(#"Pridėta rodyklė", "Indeksas Invert", each [Indeksas]*-1),
#"Pridėtas pasirinktinis2" = Table.AddColumn(#"Pridėtas pasirinktinis1","CumDebet",(i)=>List.Sum(Table.SelectRows(#"Pridėtas pasirinktinis1", each [Customer code]=i[Customer code] and [Indeksas]<=i[Indeksas]) [Debet]), type number )
in
#"Pridėtas pasirinktinis2"
thank you
Arturas
This is a really inefficient way to calculate cumulative columns in Power Query. You'll have much better performance if you used a method like List.Accumulate instead.
Check out this post for an example:
https://community.powerbi.com/t5/Desktop/How-to-do-a-running-Sum-by-group-in-Power-Query/m-p/290123
thanks, i'll try