Forum Discussion
Lookup measure
I'd modify this slightly. Your Duration column should be a column of type number, probably in Days.
Next, since your criticality is effectively your primary key, thats how we will do our lookups.
Create a calculated column with your source data, and we will use a lookup to bring across the numerical duration.
The formula we would use would be something like:
Duration Limit = LOOKUPVALUE('New Table'[DurationNumber], 'New Table'[Priority Level], [Priority Level])Where 'New Table' is the table you put into your post
[Priority Level] is assumed to be named the same in both tables.
Now that your data rows have your Start Date, End Date, and the Duration Limit, its now possible to create a calculated column that does the data math (End minus Start) and compares it to the duration limit. The result is a True/False if it was done in time or not. This might look like:
On Time = IF( DATEDIFF([Start Date], [End Date], DAY) <= [Duration Limit], TRUE(), FALSE() )