Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
DannaeMar
New Member

SUMX

Hello, I would like to add the values ​​of population per year, how would do my formula?

WhatsApp Image 2021-10-18 at 20.09.39.jpeg

 

3 REPLIES 3
v-jingzhang
Community Support
Community Support

Hi @DannaeMar 

 

Have you solved this problem? If so, kindly accept an appropriate reply as the solution or post your own solution to help other people find it quickly. Thanks.

 

Best Regards,
Community Support Team _ Jing

v-jingzhang
Community Support
Community Support

Hi @DannaeMar 

 

You want to get the result into a new column or a new table? If you would like to use Power Query to achieve it, you can use the Group By feature under Transform tab. Put Year in Group box and aggregate Population column by Sum into a new column. If you want to group by more columns like country, sex..., you can click Advanced radio box and add more group columns there. 

21102201.jpg

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

HotChilli
Super User
Super User

The simplest way is to drag 'country', 'year' and 'population' on to a table visual.  Make sure 'population' is using SUM in the fields well.  Make sure Year is set to 'Do not summarize' because it is stored as a number here and powerbi is going to want to SUM it.

If you want something more complex please explain in more detail and post the data.

Helpful resources

Announcements
July 2024 Power BI Update

Power BI Monthly Update - July 2024

Check out the July 2024 Power BI update to learn about new features.

July Newsletter

Fabric Community Update - July 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors