Forum Discussion
If statement stops working if I switch true and false
I currently have the following statement which works:
Measure2 = If([Measure] <= 0,5;[Measure];"")
However, I want the value for 'true' to be blank, and for false to be [measure].
When I change this in my measure, it gives only blanks. And more, all values in my table are suddenly blank.
I cannot see what I do wrong here though, and why it would be able to show this correctly but not when I switch the true and false.
Anonymous,
Please try the expression below.
Measure2 = If([Measure] <= 0,5,BLANK(),[Measure])
If the issue persists, please provide us more information about your report, so that we can make further analysis. You can upload a pbix file to Onedrive or any web storage and share the link. Do mask sensitive data before uploading.
Regards,
Charlie Liao
3 Replies
- v-caliao-msft
Microsoft Employee
Anonymous,
Please try the expression below.
Measure2 = If([Measure] <= 0,5,BLANK(),[Measure])
If the issue persists, please provide us more information about your report, so that we can make further analysis. You can upload a pbix file to Onedrive or any web storage and share the link. Do mask sensitive data before uploading.
Regards,
Charlie Liao
- AnonymousNot applicable
Thank you, that works for me! :)
- AnonymousNot applicable
I currently have the following statement which works:
Measure2 = If([Measure] <= 0,5;[Measure];"")
However, I want the value for 'true' to be blank, and for false to be [measure].
When I change this in my measure, it gives only blanks. And more, all values in my table are suddenly blank.
I cannot see what I do wrong here though, and why it would be able to show this correctly but not when I switch the true and false.