Forum Discussion
cplmak
4 years agoNew Member
Lookup date between two columns and return a value
Hi. I have a conundrum. I have two tables, Violations and Shift Calendar. Id like to be able to look up the RPTTIME in the Violations table against the Shift Calendar to determine which shift the vio...
- 4 years ago
cplmak , New column in DAX
Shift = maxx(filter(Table2, Table1[RPTTIme] >= Table2[Start Time] && Table1[RPTTIme] < Table2[End Time]), Table2[Shift])
Weeknum = maxx(filter(Table2, Table1[RPTTIme] >= Table2[Start Time] && Table1[RPTTIme] < Table2[End Time]), Table2[Weeknum])
amitchandak
Super User
4 years agocplmak , New column in DAX
Shift = maxx(filter(Table2, Table1[RPTTIme] >= Table2[Start Time] && Table1[RPTTIme] < Table2[End Time]), Table2[Shift])
Weeknum = maxx(filter(Table2, Table1[RPTTIme] >= Table2[Start Time] && Table1[RPTTIme] < Table2[End Time]), Table2[Weeknum])