Forum Discussion

tuncay's avatar
tuncay
Helper III
4 years ago
Solved

Create a new column

I want to create a new column, which inspects another column and if the cell contents starts with E, the new column should be: It is E. If it's B, it should be: It is B. And so on. How can I create such a column?

  • Anonymous's avatar
    Anonymous
    4 years ago

    Hello

    You can use following DAX to create column to get result.

     

    Column E or B = IF(LEFT('TableName'[ColumnName], 1) = "E", "It is E", IF(LEFT('TableName'[ColumnName], 1) = "B", "It is B"))

1 Reply

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hello

    You can use following DAX to create column to get result.

     

    Column E or B = IF(LEFT('TableName'[ColumnName], 1) = "E", "It is E", IF(LEFT('TableName'[ColumnName], 1) = "B", "It is B"))