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

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.

Reply
Anonymous
Not applicable

Help required in calculated column which uses sum()

Hello All. Below  I am attaching a picture where there's a column in my table called as "Opportunity value" and every "account manager" column can have 'n' number of "opportunities" and "opportunity value". So I need to create a calculated column in which i have to show the "Sum of the "opportunity value" mapped to the particular "account manager"" . That calculated column will be the total revenue of the account manager. Please help me with the calculated column formula. Any help would be much appreciated. Thanks in Advance!

 

 

 

6 REPLIES 6
HughLa
Resolver IV
Resolver IV

I managed to get this result.

HughLa_0-1666027703381.png

You can create a calculated table with Summarize() and return a GroupBy()

i.e.

HughLa_1-1666027789217.png

 

Then create a relationship between your tables

HughLa_2-1666027839254.png

 

I hope this is what you are trying to achieve.

 

Anonymous
Not applicable

@HughLa when i tried that i am getting this error "The expression refers to multiple columns. Multiple columns cannot be converted to a scalar value."

Is it possible for you to share your DAX?

Anonymous
Not applicable

.

@Anonymous 

Is your table name table? If so, please escape it with single quotes ''.

 

Try this:

revenue measure = var a = SUMMARIZE('table','table'[Account_Owner_Name],"total",SUM('table'[Opportunity_value]))
return
GROUPBY(a,'table'[Account_Owner_Name],[total])
 
HughLa
Resolver IV
Resolver IV

Hi @Anonymous 

 

How would you want to visualize this new column? Can you not create a measure that sums that column? Or you can enable row totals on your table?

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors