Forum Discussion
Direct Query Date Conversion in DAX - Performance Issues
- 3 years ago
This date table solution didn't seem to work for performance, but that could have been due to other constructions in my report, so I've decided to split the report into functional sub groups, in this way one report becomes many, which isn't ideal, but the populations are about 1/5 what the total report was originally. I sacrificed scope for run time.
Hi sght16
please try
Make It A Date =
VAR Year1 =
VALUE ( LEFT ( [Text Date], 4 ) )
VAR Mon1 =
VALUE ( MID ( [Text Date], 5, 2 ) )
VAR Day1 =
VALUE ( RIGHT ( [Text Date], 2 ) )
RETURN
DATE ( Year1, Mon1, Day1 )
DATE function (DAX) - DAX | Microsoft Learn says for the DATE function, "This function is not supported for use in DirectQuery mode when used in calculated columns or row-level security (RLS) rules." and I'm using this in a calculated DAX Column.
- sght163 years agoNew Member
It's a Direct Query from an ERP, so something in the order of 700K with the hard filtering limits that I placed in M Query.
- sght163 years agoNew Member
To confirm for other readers, I tried the Value + Date suggestion, and it did not work for a Calculated DAX Column. I'm working on the other suggestion and will update this post with the results when I'm finished.