Forum Discussion
Searching column for values < 2000
Hi,
I am having trouble creating a calculated column, where I search another column for values < 2000.
IF < 2000, then it shall return "Home" and IF > 2000, then "Out".
I have tried something like this
_Out_Home =
IF(Value('DM_Employee'[PersiumOrgID]) < 2000, "Home", "Out")
The column consists of non unique IDs in text format, which is why I use the Value function.
When i do this it says: " Cannot convert value '' of type Text to type Number. "
I have also tried this:
Hi Anonymous ,
I test the data your provided ,run successful(see the below).
Cannot convert value '' of type Text to type Number: It might be because one of the rows contain blank value or non numberic value. In query editor, try filtering each column for a non numeric value.
The expression refers to multiple columns. Multiple columns cannot be converted to a scalar value:refer :
Wish it is helpful for you!
Best Regards
Lucien
2 Replies
- amitchandak
Super User
Anonymous , In case you want to create a new column
_Out_Home =
IF('DM_Employee'[PersiumOrgID] < 2000, "Home", "Out") - v-luwang-msft
Community Support
Hi Anonymous ,
I test the data your provided ,run successful(see the below).
Cannot convert value '' of type Text to type Number: It might be because one of the rows contain blank value or non numberic value. In query editor, try filtering each column for a non numeric value.
The expression refers to multiple columns. Multiple columns cannot be converted to a scalar value:refer :
Wish it is helpful for you!
Best Regards
Lucien