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
chalapathy
Frequent Visitor

Target value to a column in table

I have a parameter setup for user to input target production. I have a table that have percent allocation and associated price.

Something similar to the following. Based on target, I would like to display Weighted average Price in a Card.

 

Tried Using measures for multiplying. While the Qty and Ext display properly, the Wgt. Avg is not returning proper value.

Can an

 

Target:3200Parameter Input 
     
TABLECalculated Columns
Item% AllocUnit PQty (Target*% alloc)Ext. (Qty*Unit P)
A25%22                              800                17,600
B0%40                                 -                           -  
C40%30                           1,280                38,400
D15%0                              480                         -  
E20%45                              640                28,800
     
                              3,200                84,800
     
  Wgt. Avg P 26.5 

 

 

 

1 ACCEPTED SOLUTION
v-yangliu-msft
Community Support
Community Support

Hi  @chalapathy ,

Here are the steps you can follow:

1. Create measure.

Wgt. Avg P =
DIVIDE(
    SUMX(ALL('Table'),[Qty] * [Unit P])
    ,
    SUMX(ALL('Table'),'Table'[%Alloc])* 3200)

2. Result:

vyangliumsft_0-1656645285371.png

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

View solution in original post

2 REPLIES 2
v-yangliu-msft
Community Support
Community Support

Hi  @chalapathy ,

Here are the steps you can follow:

1. Create measure.

Wgt. Avg P =
DIVIDE(
    SUMX(ALL('Table'),[Qty] * [Unit P])
    ,
    SUMX(ALL('Table'),'Table'[%Alloc])* 3200)

2. Result:

vyangliumsft_0-1656645285371.png

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

Thank  you. Sorry for the late reply. It was long weekend and holidaying.

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

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

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

Top Solution Authors