Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
1 year ago
Solved

Please can someone help me!

I have got this formula in PowerBI: 

 

Count a = if('OfficeForms Table'[Using the scale below, please let us know how supported you currently feel by the BRIDGE+ programme]=5,1,0) 
 
But receiving the below error code:
 
DAX comparison operations do not support comparing values of type Text with values of type Integer. Consider using the VALUE or FORMAT function to convert one of the values.
  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi Anonymous 

    I wanted to check if you had the opportunity to review the information provided by Greg_Deckler . Please feel free to contact us if you have any further questions. If the response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.


    Thank you.

4 Replies

  • Greg_Deckler's avatar
    Greg_Deckler
    Community Champion

    Anonymous Your column is likely text instead of a number. You can change the data type or you can do this:

    Count a = if(VALUE('OfficeForms Table'[Using the scale below, please let us know how supported you currently feel by the BRIDGE+ programme])=5,1,0) 

    or

    Count a = if('OfficeForms Table'[Using the scale below, please let us know how supported you currently feel by the BRIDGE+ programme]*1=5,1,0) 

    or

    Count a = if('OfficeForms Table'[Using the scale below, please let us know how supported you currently feel by the BRIDGE+ programme]="5",1,0) 

    or

    Count a = if('OfficeForms Table'[Using the scale below, please let us know how supported you currently feel by the BRIDGE+ programme]=5&"",1,0) 

     

  • Anonymous's avatar
    Anonymous
    Not applicable

    You have saved me from pulling my hair out or my laptop going through the window!! Thank you SO MUCH!

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous ,

    Thank you for reaching out to the Microsoft fabric community forum.

     

    May I ask if you have resolved this issue by the answer provided by Greg_Deckler ? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.

     

    Thank you.

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous 

    I wanted to check if you had the opportunity to review the information provided by Greg_Deckler . Please feel free to contact us if you have any further questions. If the response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.


    Thank you.