Power Bi Feature Series – Add column by example

By Paul Johnson | October 12, 2018

This feature allows you to create new columns of data from existing columns or clean data in your data model. It allows you to add new columns of data to your model by simply providing one or more sample values for your new column. Using columns by example allows you to complete transformations on data without needing to know the formulas. Examples of this could be trimming blank spaces, getting just part of a string, or concatenating data from different columns. In more complex examples you need to provide a power query with a few examples, so it can learn what you are trying to do.

How to use this feature:

Use Query Editor

powerbi column from example 2

Click Add column

B. Choose column by example

C. Select from all columns or from the selection. This will add a new column

As you type, it will show you a preview of the transformation that will be applied. In the example below, you will see that we are extracting everything before the - character in CUSTCLAS using the Text before the delimiter transformation.

powerbi column from example 1

You will then have to rename the column

Questions?

This is a nice tool for cleaning data quickly and the best thing is that it also works in excel using power query. If you would like to learn more reach out to the GP support team.

Paul Johnson
Our Verified Expert
Paul Johnson

Paul Johnson brings over 15 years of experience in ERP and business application consulting, with expert knowledge in Dynamics GP, Dynamics 365 Customer Engagement, Business Central, and Power Platform. As a Solutions Architect, Paul is known for designing and optimizing end-to-end solutions that bring clarity and measurable value to many types of businesses.
His recent projects include leading Dynamics GP upgrade initiatives, integrating Power BI for executive reporting, and deploying Power Platform applications for finance and operations teams. With a focus on solution scalability and system insight, Paul delivers thoughtful, well-rounded guidance across the Microsoft ecosystem.

Read More from Paul Johnson

Under the terms of this license, you are authorized to share and redistribute the content across various mediums, subject to adherence to the specified conditions: you must provide proper attribution to Stoneridge as the original creator in a manner that does not imply their endorsement of your use, the material is to be utilized solely for non-commercial purposes, and alterations, modifications, or derivative works based on the original material are strictly prohibited.

Responsibility rests with the licensee to ensure that their use of the material does not violate any other rights.

Start the Conversation

It’s our mission to help clients win. We’d love to talk to you about the right business solutions to help you achieve your goals.

Subscribe To Our Blog

Sign up to get periodic updates on the latest posts.

Thank you for subscribing!