Hi I have just installed Power BI for a test and am stuck straight away.
I have a field that I wish to report if it is empty or not. (Something like 20% Missing, %80 Found)
I initially thought that I could just apply a filter on a Pi chart but couldn't work that out, so tried to add a new column the same way I would in excel but that fails too. Can anyone put me on the right path?
I tried the following
But get the error Expression.Error: The name 'IF' Wasn't recognized.
I also tried with ISBLANK BLANK and a few others.
Solved! Go to Solution.
I'm assuming you are created a new column using DAX. If so you need to name the column. It should look something like this:
FoundTag = IF(
Actually I spoke to soon.
When I try the same soultion on another field (different table) that contains the same data it doen't find the blanks, although it is reporting the others.
I tried both
Status = IF(isBlank([UDF_CHAR1]),"Missing","Found")
Status = IF([UDF_CHAR1] = "","Missing","Found")
I don't get any errors, its just is not showing the blanks.
The only difernece between the fields is one is nvarchar(3500) and other is nvarchar(250) otherwise the have been poulated with the same script.
Screenshot where you can see the orginal working one, and the new one looking at the new field.
Check what the actual contents of the table are. In data terms, null, "", and " " are all considered different. Something as a simple as an extra space could be the cause for an issue.
If i look in SMS then it just says NULL, but i tried that too.
After i made that last post i found that i can see that actual data in powerBI, so took a look at that field and found that it is not displaying any of the blank rows, however, I can see them in the DB
udf_char1 is the new field.
Did you import the column with a different name? Looking at your SQL, should your code be:
Status = IF(isBlank([Imported MEF Expiry Date]),"Missing","Found")
What other data manipulation is occuring in your import that concerns this field? Try getting a dump of the table, as it sits in Power BI, into Excel and look at the contents.