Forum Discussion
Consolidating Text Cells in Power Query in Power BI
In Power Query within Power BI, I encounter a situation where certain text cells in columns 2, 3, and 5 start with "Visits for ...". My objective is to extract this text and consolidate it into a new, single column. Subsequently, I intend to use the "Fill Down" operation to propagate the extracted values consistently throughout the column.
However, when attempting to achieve this using a conditional column with "else if" options, I face a challenge. The conditional column setup only considers values from column 2 and disregards columns 3 and 5, resulting in a failed outcome.
I am seeking your assistance in providing an alternative approach to accomplish this task successfully. Could you please suggest the steps I should follow to address this issue?
below sample columns and expected output as new column.
In Power Query, you can create a new column that is a merge of three other columns using the "Add Column" feature.
Here's how:
Suppose you have three columns named Column1, Column2, and Column3, and you want to merge them into a new column called "MergedColumn."
- Select the table that contains the three columns in the Power Query Editor.
- Go to the "Add Column" tab in the Power Query Editor.
- Click on "Custom Column."
In the "Custom Column" dialog, enter the formula for merging the three columns using the "&" operator:
2 Replies
- fooddCommunity Champion
In Power Query, you can create a new column that is a merge of three other columns using the "Add Column" feature.
Here's how:
Suppose you have three columns named Column1, Column2, and Column3, and you want to merge them into a new column called "MergedColumn."
- Select the table that contains the three columns in the Power Query Editor.
- Go to the "Add Column" tab in the Power Query Editor.
- Click on "Custom Column."
In the "Custom Column" dialog, enter the formula for merging the three columns using the "&" operator:
- fooddCommunity Champion
Please mark it as a Solution if it has met your request so that others are able to find it easier.