Forum Discussion

powerbidev123's avatar
powerbidev123
Icon for Solution Sage rankSolution Sage
1 year ago
Solved

Convert boolean value using Value function

Hi Community,

 

I am getting this error as I am trying create a calculated column and convert Boolean value to string for comparing it with text value in another column.

 

 

Below is the sample dataset screenshot

Any help will be appreciated as to how to rectify this error

  • johnt75's avatar
    johnt75
    1 year ago

    If the exception column is a true/false type, which it looks like it is, then I don't think you need the VALUE function. You should just be able to compare the exception column to TRUE().

  • Thanks johnt75 , this worked. But still don't know how. Because we didn't convert the Boolean type to text and compared it to text value

5 Replies

  • You've got a single &, that's the concatenation operator. You need &&, which is logical AND.

    • powerbidev123's avatar
      powerbidev123
      Icon for Solution Sage rankSolution Sage

      Hi johnt75 , I have corrected it to &&, still getting the same error

      • johnt75's avatar
        johnt75
        Icon for Super User rankSuper User

        If the exception column is a true/false type, which it looks like it is, then I don't think you need the VALUE function. You should just be able to compare the exception column to TRUE().