Forum Discussion
jakaihammuda
2 years agoHelper III
DAX logic based on refresh failures or inprogress
Hello, I have a basic 3 column table. However the logic i want to implement i cant quite figure out. Essentially all i want to do is the following: If the [statusname] of a report is either F...
- 2 years ago
Hi, jakaihammuda
try belowlatest status = var a = MAXX(all('status'[Load Start Timestamp]),'status'[Load Start Timestamp]) VAR b = MINX(FILTER(ALL('status'),'status'[Entity Name]=MAX('status'[Entity Name]) && 'status'[Load Start Timestamp]=a), 'status'[Status Name] ) var c = MAXX(FILTER(ALL('status'),'status'[Status Name]="succeeded" && 'status'[Entity Name]=MAX('status'[Entity Name])), 'status'[Load Start Timestamp]) var d = IF(b<>"succeeded",c) RETURN d
jakaihammuda
2 years agoHelper III
This still takes the load timestamp of the one that failed when it should be last successful..
if the 18th failed (today/latest status) then that should appear as the acualy status
but for the load timestamp (which i use to show how up to date the data is) i want to use whatever the last successful load start timestamp was. whilst still having the status as Failed - because it did fail the load time stamp (data) didnt update
Dangar332
2 years agoResident Rockstar
hi, jakaihammuda
Measure 3 =
var a = CALCULATE(max('status'[Load Start Timestamp]),ALLEXCEPT('status','status'[Entity Name]))
var b = CALCULATE(MIN('status'[Status Name]),KEEPFILTERS('status'[Load Start Timestamp]=a))
var c = MAXX(
FILTER( 'status',[Entity Name]=MAX([Entity Name]) && [Status Name]="succeeded"),
[Load Start Timestamp])
RETURN
SWITCH(TRUE(),
b="failed",c,c)- jakaihammuda2 years agoHelper III
Doesnt seem to work.
no worries ill see if theres anything else i can do. Thank you nontheless. - Dangar3322 years agoResident Rockstar