Forum Discussion
Siddhesh_Pal
Advocate II
2 years agoNeed help in the pricing calculation.
I have a Pricing table and Customer GMV from another table, based on Customer GMV, we have to take the reference row and calculate in that row to get the final amount. Pricing Table Ref. ...
- Anonymous2 years ago
I made a sample dataset using the table you provided, I believe the below measure is behaving as you would want it to:
Raw measure code:
GMV Calc =VAR _GMV = 400000 /*Replace with your actual gmv column/measure*/VAR _table = FILTER('Main Data Table', _GMV > 'Main Data Table'[Volume Minimum])RETURNSUMX(_table, (IF(_GMV > [Volume Maximum], [Volume Maximum], _GMV) - (IF([Volume Minimum] = 0, [Volume Minimum], [Volume Minimum] - 1))) * [BPS])
Anonymous
2 years agoNot applicable
I made a sample dataset using the table you provided, I believe the below measure is behaving as you would want it to:
Raw measure code:
GMV Calc =
VAR _GMV = 400000 /*Replace with your actual gmv column/measure*/
VAR _table = FILTER('Main Data Table', _GMV > 'Main Data Table'[Volume Minimum])
RETURN
SUMX(_table, (IF(_GMV > [Volume Maximum], [Volume Maximum], _GMV) - (IF([Volume Minimum] = 0, [Volume Minimum], [Volume Minimum] - 1))) * [BPS])
Siddhesh_Pal
Advocate II
2 years agoHi Anonymous, Thanks for your help.
The solution is working perfectly for me.