Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I am working with a list as follows :
{"x", "100","200")
And I want to sum only the 100 and 200, skipping the text string [the text string is not at a fixed loaction in all the lists, so list.skip does not work).
Is there some combination of List.Sum and List.Transform to acheive this task?
Thanking in advance
Solved! Go to Solution.
See here
List.Sum(List.Transform({"x", "100","200", "x300", 500}, (x)=> if Value.FromText(x) is number then Value.FromText(x) else 0 ))
See here
List.Sum(List.Transform({"x", "100","200", "x300", 500}, (x)=> if Value.FromText(x) is number then Value.FromText(x) else 0 ))
Thanks @Vijay_A_Verma - that worked like a charm. I was missing using the function, which simplifies the code.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.