Forum Discussion
Dax to Powerquery
Power query from dax?
Hello can anyone help me optimize this query from dax into Powerquery?
Assuming these are all column references it would be something like the following
if [CONSENT] ="CSC" then
if [OUTCOME_Msh_FLAG] ="Y" then
if [Msh_DEC_DTTM] = null then -1
else [Msh_Timeliness]
else [Timeliness]
else [Timeliness]- Anonymous5 years ago
Hi jaltoft
In Power query , the formula for IF function is like this:
if "if-condition" then "true-expression" else "false-expression"So for your Dax ,we can convert it like this:
if [CONSENT]="CSC" then if [OUTCOME_Msh_FLAG]="Y" then if [Msh_DEC_DTTM]=null then -1 else [Msh_Timeliness] else [Timeliness] else [Timeliness]And the result is the same as DAX
Best Regards
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- d_gosbellSuper User
Assuming these are all column references it would be something like the following
if [CONSENT] ="CSC" then
if [OUTCOME_Msh_FLAG] ="Y" then
if [Msh_DEC_DTTM] = null then -1
else [Msh_Timeliness]
else [Timeliness]
else [Timeliness] - AnonymousNot applicable
Hi jaltoft
In Power query , the formula for IF function is like this:
if "if-condition" then "true-expression" else "false-expression"So for your Dax ,we can convert it like this:
if [CONSENT]="CSC" then if [OUTCOME_Msh_FLAG]="Y" then if [Msh_DEC_DTTM]=null then -1 else [Msh_Timeliness] else [Timeliness] else [Timeliness]And the result is the same as DAX
Best Regards
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.