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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Syndicate_Admin
Administrator
Administrator

Get Last Registration Status

Good I have the following table that contains duplicates with the different states of a folio (claim), pass the data to excel to explain. And another table where all the claims are then I need to get the last status of the claim by history date, has another date entry field. The case marked for that folio would be to obtain that status "completed operations (b)" but I could not find the DAX

Icaros_0-1654302367961.png

-thank you very much!

1 ACCEPTED SOLUTION
v-zhangti
Community Support
Community Support

Hi, @Syndicate_Admin 

 

You can try the following methods.

Column:

Latest Time = 
CALCULATE (
    MAX ( 'Table'[FCH_HISTORIAL] ),
    FILTER ( 'Table', [FOLIO] = EARLIER ( 'Table'[FOLIO] ) )
)
Last Registration Status =
CALCULATE (
    MAX ( 'Table'[GLS_ESTADO] ),
    FILTER ( 'Table', [FCH_HISTORIAL] = EARLIER ( [Latest Time] ) )
)

vzhangti_1-1654581216430.png

Is this the result you were hoping for? If not, see the Blog below for your example file. Please also provide the output you expect. How to provide sample data in the Power BI Forum - Microsoft Power BI Community

 

Best Regards,

Community Support Team _Charlotte

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
v-zhangti
Community Support
Community Support

Hi, @Syndicate_Admin 

 

You can try the following methods.

Column:

Latest Time = 
CALCULATE (
    MAX ( 'Table'[FCH_HISTORIAL] ),
    FILTER ( 'Table', [FOLIO] = EARLIER ( 'Table'[FOLIO] ) )
)
Last Registration Status =
CALCULATE (
    MAX ( 'Table'[GLS_ESTADO] ),
    FILTER ( 'Table', [FCH_HISTORIAL] = EARLIER ( [Latest Time] ) )
)

vzhangti_1-1654581216430.png

Is this the result you were hoping for? If not, see the Blog below for your example file. Please also provide the output you expect. How to provide sample data in the Power BI Forum - Microsoft Power BI Community

 

Best Regards,

Community Support Team _Charlotte

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Syndicate_Admin
Administrator
Administrator

hello good, how do I apply those formulas in each table? I mean the one that contains the duplicates and the other one that is without duplicates? , what does it mean?

Ashish_Mathur
Super User
Super User

Hi,

For Folio 3398917, there are 2 different status for the same Date/time stamp.  Why should the result be "completed operations (b)"?  Why not "En GestionOperaciones (b)"?

Please also share the download link of the PBI file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
amitchandak
Super User
Super User

@Syndicate_Admin , new column example

 

new column in Table 2 =
var _max = Maxx(filter(Table1, Table2[folio] = Table1[folio] ), [history date])
return
Maxx(filter(Table1, Table2[folio] = Table1[folio] && [history date] = _max ),[Status] )


new column in Table1 (self) =
var _max = Maxx(filter(Table1, Table1[folio] = earlier(Table1[folio]) ), [history date])
return
Maxx(filter(Table1, Table1[folio] = earlier(Table1[folio]) && [history date] = _max ),[Status] )

Amigo no i know what it means return, supono which is Return translated into Spanish from enter. Attached the file there are two tables in which I need the data is in the table called claims, the other is the table that contains the duplicates with the historical data that I need the last oldest. where does the option to attach file appear?

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

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.