Don't miss your chance to take exam DP-600 or DP-700 on us!
Request nowLearn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Hi all please how would I write this below statement in DAX, been trying to convert this SQL query but I keep getting an error
SQL Script
COALESCE(SUM(CASE WHEN ((CASE WHEN X THEN 1 ELSE 0 END
) = 0) AND (y is not null) THEN datediff(minute, x, x)* 1.0 / 60 ELSE NULL END), 0)
Any Recommendation will be much appreciated
Solved! Go to Solution.
@Anonymous , Correct the condition X<> 0
Sumx(Table, if( if([X] <>0, 1,0)=0 && not(isblank([Y])) , datediff([d1], [d2],minute)/60,blank()))
This should be a measure
@Anonymous , Correct the condition X<> 0
Sumx(Table, if( if([X] <>0, 1,0)=0 && not(isblank([Y])) , datediff([d1], [d2],minute)/60,blank()))
This should be a measure
| User | Count |
|---|---|
| 50 | |
| 41 | |
| 32 | |
| 14 | |
| 13 |
| User | Count |
|---|---|
| 84 | |
| 72 | |
| 37 | |
| 27 | |
| 24 |