Forum Discussion

anandprakashnm's avatar
anandprakashnm
Frequent Visitor
10 years ago
Solved

Create column with "Like in SQL"

Hello,   I am trying to group some of the data with a new column identifier and i have a lot of identifier. I want to use something like this:-   new column = if([column1] like "B%", "Ball", if([...
  • v-haibl-msft's avatar
    10 years ago

    anandprakashnm

     

    As KGrice said, you can create a new column by using the SEARCH function like below. BTW, the search function is case insensitive.

    Column = 
    IF (
        SEARCH ( "B*", Table1[column1],, 0 ) = 0,
        IF ( SEARCH ( "A*", Table1[column1],, 0 ) = 0, "Others", "Apple" ),
        "Ball"
    )

     

    Best Regards,

    Herbert