Forum Discussion
Getting value from 2 columns to create one column
- 1 year ago
Hi igonzalez_ep
First, I would confirm that the columns contain true blank values.
One method: in Table view, click the filter dropdown:
Empty string (not blank)
Actual Blank:
You may need to replace empty string values with nulls in Power Query:
Null values in Power Query will appear as italicised null in the Power Query Editor.
Once you are sure you have blank values in the relevant columns, you could create this DAX calculated column:
= COALESCE ( YourTable[ColumnA], YourTable[ColumnB], "null" )You could also add a custom column in Power Query with this expression (using the null-coalescing operator ?? )
= [ColumnA] ?? [ColumnB] ?? "null"Does any of the above help?
Hi igonzalez_ep
First, I would confirm that the columns contain true blank values.
One method: in Table view, click the filter dropdown:
Empty string (not blank)
Actual Blank:
You may need to replace empty string values with nulls in Power Query:
Null values in Power Query will appear as italicised null in the Power Query Editor.
Once you are sure you have blank values in the relevant columns, you could create this DAX calculated column:
= COALESCE ( YourTable[ColumnA], YourTable[ColumnB], "null" )
You could also add a custom column in Power Query with this expression (using the null-coalescing operator ?? )
= [ColumnA] ?? [ColumnB] ?? "null"
Does any of the above help?