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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
Anonymous
Not applicable

Help Please with Calculated Table Logic

Hi all,

 

Looking for some help to think through this dax calculation I'm trying to come up with:

 

I have robot log data based on queues for a couple of months. Each line item is a transaction of some sort. It could have a status of Successful, failed, abandonded, retried. For all of the cases that have retried, they try again and again until it goes to successful, failed, or abandonded.


This is what I want to do: I'd like to summarize a new table with ALL 'keys' that have "retried" at least once, then retrieve the MAX date of that KEY to see what the outcome at the end was. It'll never end on retried. It'll end up being Successful, Failed, or Abandoned. I hope this is somewhat clear:

 

Here are the useful/relevant fields I have: Key, status, started, ended, transaction execution time, etc.

 

Would appreciate anyones input.


Thank you!

1 ACCEPTED SOLUTION

Maybe I see what you mean. Please try the DAX below.

Table = 
FILTER('Table (2)',
'Table (2)'[Date]=CALCULATE(MAX('Table (2)'[Date]),ALLEXCEPT('Table (2)','Table (2)'[Key]))
&&CALCULATE(COUNT('Table (2)'[Key]),ALLEXCEPT('Table (2)','Table (2)'[Key]))>1)

Vlianlmsft_0-1628842004739.pngVlianlmsft_1-1628842021105.png

 

For more details, please refer to the sample .pbix.

 

View solution in original post

5 REPLIES 5
PaulDBrown
Community Champion
Community Champion

Sorry, I should have been more specific...Please provide sample data in table format (as in data). We cannot work on an image. Thanks!





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






Anonymous
Not applicable

Will a CSV file work?

Maybe I see what you mean. Please try the DAX below.

Table = 
FILTER('Table (2)',
'Table (2)'[Date]=CALCULATE(MAX('Table (2)'[Date]),ALLEXCEPT('Table (2)','Table (2)'[Key]))
&&CALCULATE(COUNT('Table (2)'[Key]),ALLEXCEPT('Table (2)','Table (2)'[Key]))>1)

Vlianlmsft_0-1628842004739.pngVlianlmsft_1-1628842021105.png

 

For more details, please refer to the sample .pbix.

 

PaulDBrown
Community Champion
Community Champion

please provide some sample data and the expected output. Thanks!





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






Anonymous
Not applicable

rzavgazaryan_0-1628525375244.png

Here are all of the relevant fields here. Key, Status, Ended, Exception Reason. For any cases where there are 'Retries' in 'Status' column, that means that there are duplicates in the Key column. I want some sort of outcome like this:

 

rzavgazaryan_1-1628525605247.png

 

So it'll show me any keys that once were retired, it retries the MAX date of all retried cases which tells me what ended up happening int he end. PLease let me know if this is enough information.

 

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.