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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Mniknejad
Frequent Visitor

Wrong total amount

I am creating a measure like this

[Un-Allocated]*[SalesUnitPrice test]
it's number of ordrer multipy with unit price  in subtotal I am getting wron number becuase 
it ganna multipy  sum([Un-Allocated]) * sum ([SalesUnitPrice test]) and I don't want it I don't know how can I resolve this ?
1 ACCEPTED SOLUTION
Anonymous
Not applicable

I think you have a few options with this.  You can perform the calculation as a calculated column.  For every Row Un-Allowcated * SalesUnprice.  Then simply wrtie a measure for that calculated column.  Or you can use SUMX.

 

That would look like the following..  SUMX( <Table>, UnAllocated Column * SalesUnit Price)

This sumx will iterate through the granularity put in table.  It can be very expensive if your fact table is very large, if that is the case I recommend performing a calculated column.  The X functions are great when you create a small summarize/filtered list that should need to be itterated through.  Try getting close and post if you don't get it.  Also if need help implementing please publish the tables and relationships needed for this measure.

View solution in original post

1 REPLY 1
Anonymous
Not applicable

I think you have a few options with this.  You can perform the calculation as a calculated column.  For every Row Un-Allowcated * SalesUnprice.  Then simply wrtie a measure for that calculated column.  Or you can use SUMX.

 

That would look like the following..  SUMX( <Table>, UnAllocated Column * SalesUnit Price)

This sumx will iterate through the granularity put in table.  It can be very expensive if your fact table is very large, if that is the case I recommend performing a calculated column.  The X functions are great when you create a small summarize/filtered list that should need to be itterated through.  Try getting close and post if you don't get it.  Also if need help implementing please publish the tables and relationships needed for this measure.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.