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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
selected_
Helper IV
Helper IV

Possible to recalculate a measure to another measure again?

If I have a measure already that name Selling Price, the measure selling price look like this

AVERAGE('Products'[UnitPrice]) * ([Total Discount])
 
can I then create a new measure and calculate MAX and MIN for the measure?
 
I tried with this  MAX of Selling price = CALCULATE(MAX([Selling Price])) 
 
but got error.
1 ACCEPTED SOLUTION
v-kelly-msft
Community Support
Community Support

Hi @selected_

 

Yes,you can create 2 measures similarly as below:

Min sales price = MinX(VALUES('Table'[UnitPrice]),'Table'[Selling Price])
Max sales price = MAXX(VALUES('Table'[UnitPrice]),'Table'[Selling Price])

And you will see:

Annotation 2020-09-11 101643.png

For the related .pbix file,pls see attached.

 

Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!

View solution in original post

2 REPLIES 2
v-kelly-msft
Community Support
Community Support

Hi @selected_

 

Yes,you can create 2 measures similarly as below:

Min sales price = MinX(VALUES('Table'[UnitPrice]),'Table'[Selling Price])
Max sales price = MAXX(VALUES('Table'[UnitPrice]),'Table'[Selling Price])

And you will see:

Annotation 2020-09-11 101643.png

For the related .pbix file,pls see attached.

 

Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
Greg_Deckler
Super User
Super User

@selected_ This looks like a measure aggregation problem. See my blog article about that here: https://community.powerbi.com/t5/Community-Blog/Design-Pattern-Groups-and-Super-Groups/ba-p/138149

The pattern is:
MinScoreMeasure = MINX ( SUMMARIZE ( Table, Table[Group] , "Measure",[YourMeasure] ), [Measure])
MaxScoreMeasure = MAXX ( SUMMARIZE ( Table, Table[Group] , "Measure",[YourMeasure] ), [Measure])
AvgScoreMeasure = AVERAGEX ( SUMMARIZE ( Table, Table[Group] , "Measure",[YourMeasure] ), [Measure])
etc.


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

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.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

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