fbpx
[email protected] +1 203-349-9909 / +91-8080042523

Best Ways to Add Column From Examples in Power Query

Sometimes we need to transform the text from a huge data table which is not directly possible. But, with Power Query, you can easily do it using Add Column from Examples feature.

Add Column From Examples By Power Query

Step 1- Select the column on which you want to apply changes

Suppose you have a data table as shown in below picture where you want to remove the delimiter ‘-‘ from each row and change the case of the text. Then, you have to first select that column for applying changes.

SELECT COLUMN TO APPLY ADD COLUMN FROM EXAMPLES FEATURE

Step 2- Add Column from Examples using From Selection option

To add a new column in Power Query, go to –

Add Column  >  Column From Examples  >  From Selection

SELECT COLUMN TO APPLY ADD COLUMN FROM EXAMPLES FEATURE

BECOME A BUSINESS INTELLIGENCE ANALYST COURSE
• Power BI • Excel to Alteryx • SQL Programming Language • SAS Programming • Tableau • KNIME • many more

 

Step 3- Make changes to the selected column using Add Column from Examples

Power Query gives you access to edit the column you selected after clicking on From Selection option of Column From Examples button. You just have to replace the text in the first row as you want and the rest Power Query will do for you! As you can see in the below picture, Power Query generates a preview in the new column and you just have to click on OK if the preview is as per your expectation.

ADD COLUMN FROM EXAMPLES

Step 4- Close & Apply

Click on Close and Apply button after you get the expected result as below.

AFTER ADDING COLUMN FROM EXAMPLES

You can learn more :