Forum Discussion

FredChew's avatar
FredChew
Frequent Visitor
5 years ago
Solved

Error with alpha numeric comparsion

Hi there,

 

I am trying to compare a column with email address (as table) that starts with an alphabet eg [email protected] , but it doesn't seems to work. But when I removed the u in the beginning on both the record and the script i was able to get a return of '1'. why is that so? 

 

Measure =
CALCULATE (
IF (
MIN ('Courses_and_Teachers'[user])
1,
0
)
)
 
  • Hi FredChew ,

     

    Your measure works well based on my test, there may be something wrong with your raw data. You can also try :

     

    Measure = 
    IF(EXACT("[email protected]",MAX(Courses_and_Teachers[user])),1,0)

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

    Best Regards,

    Dedmon Dai

2 Replies

  • v-deddai1-msft's avatar
    v-deddai1-msft
    Community Support

    Hi FredChew ,

     

    Your measure works well based on my test, there may be something wrong with your raw data. You can also try :

     

    Measure = 
    IF(EXACT("[email protected]",MAX(Courses_and_Teachers[user])),1,0)

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

    Best Regards,

    Dedmon Dai