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

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
AVZ
Frequent Visitor

Using MIN and WHERE

Hi,

 

I have a table with two columns named FORWARDER_CODE and DURATION, I would like to use the min max and avg functions on duration and show the results per unique forwarder_code. Any help would be greatly appreciated.

1 ACCEPTED SOLUTION

Hello,

 

After creating the measure, try creating a table and put forwarder code and this measure. You should see the minimum for each forwarder code. If it is not coming then you must have more than two tables in your dataset and then the issue is there in relationship between them

View solution in original post

7 REPLIES 7
prateekraina
Memorable Member
Memorable Member

Try using Quick Measures and or else you can create measures of your own.
Example:

MinimumDuration = MIN(DURATION)

I have tried this, but the problem is that it shows the min value of the whole column instead of the min value per forwarder code.

Hello,

 

After creating the measure, try creating a table and put forwarder code and this measure. You should see the minimum for each forwarder code. If it is not coming then you must have more than two tables in your dataset and then the issue is there in relationship between them

HI @AVZ

 

Try this MEASURE

 

MEASURE=
CALCULATE (
    MIN ( TableName[Duration] ),
    ALLEXCEPT ( TableName, TableName[FORWARDER_CODE] )
)

Hi Zubair,

 

Thank you for your comment!

I get the same result i got earlier while using: MIN(test123[Duration]

It shows me the lowest value in the duration column, I would like it to show me the lowest value per FORWARDER_CODE.

I have forwarder codes named DPD, UPS, DHL, PNL and ROY, I would like to see the min value per each one of those codes.

@AVZ

 

Could you post a snaphot of the Table and RESULTS you are getting?

It has been resolved thanks for helping me out!

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.