Forum Discussion
dwightman2176
2 years agoFrequent Visitor
Return MAX value into column
Hi. If anyone could help with this I would be most appreciative 🙂 As a bit of background: I have a table (Issues) that lists all records that we create for IT related incidents For major i...
- 2 years ago
Download PBIX file with the example below
This works for me
MAX Downtime Per Incident = VAR _MaxDT = CALCULATE(MAX('DataTable'[Downtime]), FILTER(ALL('DataTable'), SELECTEDVALUE('DataTable'[Issue ID]) = 'DataTable'[Parent ID])) RETURN IF(SELECTEDVALUE('DataTable'[Issue Type]) = "Incident", _MaxDT)In the table visual make sure that Issue ID is set to Show items with no data
Regards
Phil
PhilipTreacy
2 years agoSuper User
Download PBIX file with the example below
This works for me
MAX Downtime Per Incident =
VAR _MaxDT = CALCULATE(MAX('DataTable'[Downtime]), FILTER(ALL('DataTable'), SELECTEDVALUE('DataTable'[Issue ID]) = 'DataTable'[Parent ID]))
RETURN IF(SELECTEDVALUE('DataTable'[Issue Type]) = "Incident", _MaxDT)
In the table visual make sure that Issue ID is set to Show items with no data
Regards
Phil
dwightman2176
2 years agoFrequent Visitor
Hi PhilipTreacy
The solution you gave populates the MAX downtime value in a table visual, but is there a way to get the same value populated in a calculated column, so that it returns the MAX value for rows which have incidents, but returns a blank for the rows that relate to sub-tasks?
Thanks
David