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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
hanami001
Frequent Visitor

Multiply Calculation in Subtotal

Hi Everyone,

 

I am using multiple formulas to calculate filed but I found in a Subtotal column is incorrect.

 

Capture01.PNG

 

On column: Deduct Rate, I use formula = Amount_THB * Number of CPN. The value in row B, H, V and Y is correct but row Subtotal is incorrect. I want to row Subtotal is calculating = row: B+H+V+Y, please advise me.

 

Deduct Rates = SUMX('Interline Rate',[Amount_THB])*SUMX(vw_nw_sale_info_01,[Number of CPN])

 

Thank you.

1 ACCEPTED SOLUTION

Hi Ross73312,

 

This problem is solved.

 

I have used another way, an insert a new column and use the formula to get data, an example is below.

 

Deduct Rates = LOOKUPVALUE('Interline Rate'[Amount_THB],
   'Interline Rate'[Carrier],vw_nw_sale_info_01[Carrier Uplifted],
   'Interline Rate'[Routing_Bi],RELATED('Routing Bi'[Route_Bi]),
   'Interline Rate'[RBD],vw_nw_sale_info_01[CLASS]
)
% Change Deduct = [Revenue] - [Deduct Rates]

Capture1111.PNG

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

Try:

First create this

Deduct Rates Measure = 'Interline Rate'[Amount_THB] * 'vw_nw_sale_info_01'[Number of CPN]

Now you can use

Deduct Rates = SUMX(
        VALUES('Interline Rate'[Routing_BI]),
        [Deduct Rates Measure]
)

 

 

Hi Ross73312,

 

Thank you for your reply.

 

I forget attached relationship of tables.

 

Capture02.PNG

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

I cannot relation between 'vw_nw_sale_info_01'[Number of CPN] and 'Interline Rate'[Amount_THB].

Anonymous
Not applicable

That might be the killer part to your problem.  You will need to figure out a way to relate the data if you wish to do this.  Conceptually, is there anything that relates the two tables?

Hi Ross73312,

 

This problem is solved.

 

I have used another way, an insert a new column and use the formula to get data, an example is below.

 

Deduct Rates = LOOKUPVALUE('Interline Rate'[Amount_THB],
   'Interline Rate'[Carrier],vw_nw_sale_info_01[Carrier Uplifted],
   'Interline Rate'[Routing_Bi],RELATED('Routing Bi'[Route_Bi]),
   'Interline Rate'[RBD],vw_nw_sale_info_01[CLASS]
)
% Change Deduct = [Revenue] - [Deduct Rates]

Capture1111.PNG

Anonymous
Not applicable

Glad you figured out a path to a solution 🙂

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

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! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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