Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago

How to dynamically calculate the minimum value

Hi All,

 

I have got this problem where I am trying to calculate the minimum of the column and subsequently use that value in calculation of the further expressions.

Minimum Price = For an item (Eg. A) in period (Eg. P1) we should be having the minimum value.

Revenue at Minimum Price = For the minimum value calculated above we need to multiply it with the volume to get this expression.

Difference = Revenue – Revenue at Minimum Price

Scenario

 

When I now deselect a country, in this case let’s say I deselect country UAE

 

 

The data model I am getting is in a star schema where the Period comes from “reporting dates” table, region and country from the “customer” table, item from “product” table and the volume, price and value are from the “fact” table.

 

Please help in writing the DAX for the Minimum Price, Revenue at Minimum Price and Difference.

No Replies