Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello everyone,
I am struggling with what seems like a simple task. I am new to Power Bi and using a directy query, my vaules are 1,2,3,4,5, etc. in a field called Types and I want to repalce the Ids with a friendly name, 1= Marketing, 2=PSA, etc.
I Created a new colum and called it pNames. I have tried using the IF function with something like
=IF(Query1[TYPES]="1", "MARKETING") on my pType field I receive "Model object names must be non-empty"
What function and syntax would I use for this?
Hi @AspireCraig ,
I tried working on your example but it works for me without any problem.
your IF formula is also correct. Dont know why you are getting this error. ( May be try to chnage the datatype because you replace)
or else you can try this
In Query editor, you can select the column Types and right click-> replace values.
Just make sure your changing the datatype to text. ( since you are replacinmg the numerical values with a text values)
Also take a look at this post with similar error:
Thanks,
Tejaswi
Hi @Tejaswi
Changing the type to text would be too easy, it appears this cannot be done when using a direct query importing will not work as this is live data. From what I can tell all the records have a value set on them. There are no empty or null values on the 'Types' field.
Anything else to try?
User | Count |
---|---|
98 | |
90 | |
78 | |
71 | |
64 |
User | Count |
---|---|
112 | |
96 | |
95 | |
67 | |
65 |