Forum Discussion
PhotoBiker
Advocate I
8 years agoProblem with "DateAdd" as measure
Hi, I'm trying to add 6 months to a list of dates. I'm connecting Power BI "live" to an SSAS data model, therefore I can't add calculated columns (which otherwise would be the simplest solut...
- 8 years ago
Phil_Seamark
Microsoft Employee
8 years ago- PhotoBiker8 years ago
Advocate I
Hi Phil_Seamark,
Thank you very much for putting me on the right track. I didn't know about edate, and it works perfectly, I just needed the following "workaround":
Edate didn't allow me to reference to any of the existing dates (Start, Referral), it only allowed me to reference another measure. So I set up a measure "MaxReferralDate" and "MaxStartDate", and then I added 6 months via edate(MaxReferralDate, 6).
(I have a sense that it might be a bit of a "brute force" approach, but as I'm digging deeper into filter and row context, maybe I'll find an (even) more elegant solution.)
But this absolutely works for my purpose, so thank you very much!