Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Does anyone know why and how to stop this code giving me a TRUE/FALSE in my calculated column?
Validation to Closure = IF(ISBLANK('Cases'[applicationvalidationdate]),BLANK() || IF(ISBLANK('Cases'[Resolution Date]),BLANK(),
DATEDIFF('Cases'[applicationvalidationdate],'Cases'[Resolution Date],DAY))+1)
It is something to do with the || (OR) operator because without the || there is no TRUE/FALSE only a DATEDIFF Count.
IF(ISBLANK('Cases'[applicationvalidationdate]),BLANK(),
DATEDIFF('Cases'[applicationvalidationdate],'Cases'[Resolution Date],DAY))+1
Thanks
Solved! Go to Solution.
Yes. If you have A || B, then the expected result is true/false.
Did you mean to write your measure like this:
Validation to Closure =
IF (
ISBLANK ( 'Cases'[applicationvalidationdate] ) || ISBLANK ( 'Cases'[Resolution Date] ),
BLANK (),
DATEDIFF ( 'Cases'[applicationvalidationdate], 'Cases'[Resolution Date], DAY ) + 1
)
Hi,
The OR statement shouldn'e be an issue, might be the way it's worded with 2 If statements instead of just 1 with an OR. Try this:
If I answered your question, please mark my post as solution, Appreciate your Kudos 👍
Hi,
The OR statement shouldn'e be an issue, might be the way it's worded with 2 If statements instead of just 1 with an OR. Try this:
If I answered your question, please mark my post as solution, Appreciate your Kudos 👍
Thanks for the quick reply - that works!
Yes. If you have A || B, then the expected result is true/false.
Did you mean to write your measure like this:
Validation to Closure =
IF (
ISBLANK ( 'Cases'[applicationvalidationdate] ) || ISBLANK ( 'Cases'[Resolution Date] ),
BLANK (),
DATEDIFF ( 'Cases'[applicationvalidationdate], 'Cases'[Resolution Date], DAY ) + 1
)
This is perfect - many thanks!
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
107 | |
97 | |
75 | |
63 | |
62 |
User | Count |
---|---|
142 | |
104 | |
104 | |
80 | |
66 |