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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
drrai66
Resolver I
Resolver I

HOW can I get Similar Result of Tableau in POWER BI with Calculation Please

Hi Experts,

Hello to Everyone. I am a new POWER BI user, but Heavy user of Tableau. I have the following Three Columns of Data in my Table.

 

IDStatusChanged Date
2303A11/7/2017 14:00
2303A11/7/2017 14:01
2303A11/7/2017 14:01
2303A11/7/2017 14:02
4657B11/6/2017 14:53
4657B11/6/2017 14:53
4657B11/8/2017 10:51
4988C11/8/2017 11:18
4988C11/9/2017 11:05
4988C11/9/2017 11:08
4988C11/9/2017 11:10

 

Using the Following LOD Expression in Tableau

 

{FIXED [ID],[Status]:MAX([Changed Date])}

 

 Which Simply Says that for a Particular ID and Status Find out the Maximum Date from Many Changed Dates Available for that Combination of ID and Status.

 So When I Use the above Formula, I get MAX Date in additional Column

 

IDStatusChanged DateMAX Date
2303A11/7/2017 14:0011/7/2017 14:02
2303A11/7/2017 14:0111/7/2017 14:02
2303A11/7/2017 14:0111/7/2017 14:02
2303A11/7/2017 14:0211/7/2017 14:02
4657B11/6/2017 14:5311/8/2017 10:51
4657B11/6/2017 14:5311/8/2017 10:51
4657B11/8/2017 10:5111/8/2017 10:51
4988C11/8/2017 11:1811/9/2017 11:10
4988C11/9/2017 11:0511/9/2017 11:10
4988C11/9/2017 11:0811/9/2017 11:10
4988C11/9/2017 11:1011/9/2017 11:10

 

So for all the Dates in 3rd Column , I get Only 3 Dates for a particular ID and its Corresponding Status which are the MAXIMUM dates I Need

 

How Can I Get the 4th Column  (MAX DATE) in POWER BI with some Formula. Can somebody provide the FORMULA?

Thanks a Lot

Deepak

1 ACCEPTED SOLUTION
Vvelarde
Community Champion
Community Champion

@drrai66

 

Hi, you can usea a calculated column:

 

MaxDate =
CALCULATE (
    MAX ( Table1[Changed Date] ),
    FILTER (
        Table1,
        Table1[ID] = EARLIER ( Table1[ID] )
            && Table1[Status] = EARLIER ( Table1[Status] )
    )
)

Regards

 

Victor

Lima - Peru 




Lima - Peru

View solution in original post

2 REPLIES 2
Vvelarde
Community Champion
Community Champion

@drrai66

 

Hi, you can usea a calculated column:

 

MaxDate =
CALCULATE (
    MAX ( Table1[Changed Date] ),
    FILTER (
        Table1,
        Table1[ID] = EARLIER ( Table1[ID] )
            && Table1[Status] = EARLIER ( Table1[Status] )
    )
)

Regards

 

Victor

Lima - Peru 




Lima - Peru

Victor, Thanks Man!!, This is what I was looking for.

Thanks

Deepak

 

Max Date.PNG

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.