Forum Discussion
Anonymous
6 years agoNot applicable
CASE STATEMENT TO DAX?
Hi Community,
I want to convert this CASE STATEMENT SQL Query to DAX?
SQL Query:
1. DayDiff(AddMonths(min(month),3),min(month)) AS tot_days, (Measure 1)
2. CASE WHEN daydiff(Now(),min(month)) > DayDiff(AddMonths(min(month),3),min(month)) THEN DayDiff(AddMonths(min(month),3),min(month)) ELSE daydiff(Now(),min(month)) end AS days_completed (Measure 2)
Is it possible?
Reg,
Dhana
5 Replies
- AnonymousNot applicableEverything is possible but without knowing anything about the tabular model, without knowing the tables and relationships involved... not much can be done in this case, I'm afraid.
Best
D- AnonymousNot applicable
this is the model view (Deals_Active) is my fact table here. Any Idea?
- AnonymousNot applicable
Anonymous
give some idea, instead of "Addmonths" what i can use there? I mean alternate DAX function.
- AnonymousNot applicable