How To Add Column In Power Bi

Adding a Column in Power BI

To add a column in Power BI, you need to follow these steps:

  1. Open your Power BI Desktop application.
  2. Open the report or dataset you want to work with.
  3. Click on the “Edit Queries” button located in the “Home” tab.
  4. A separate window will open, displaying the Power Query Editor.
  5. In the Power Query Editor, select the table or query from the “Queries” pane on the left-hand side.
  6. Click on the “Add Column” tab in the ribbon.
  7. Choose the type of column you want to add. You can select from options like “Custom Column”, “Conditional Column”, “Date”, “Text”, etc.
  8. Once you select the type of column, a dialog box will open where you can define the column name, formula, and any additional settings specific to the column type you chose.
  9. Enter the required information and click on the “OK” button to add the column.
  10. After adding the column, you can perform various operations like sorting, filtering, formatting, etc. on the column data in the Power Query Editor.
  11. Once you are done with the column modifications, click on the “Close & Apply” button to apply the changes and go back to your report.

Here’s an example to help you understand the process better:

Let’s say you have a table in Power BI with two columns – “Product Name” and “Price”. You want to add a new column that displays the discounted price. Follow the steps mentioned above:

  1. Open Power BI Desktop and your desired report or dataset.
  2. Click on “Edit Queries”.
  3. Select the table containing the data.
  4. Click on “Add Column” and choose “Custom Column”.
  5. In the dialog box, enter “Discounted Price” as the column name.
  6. Define the formula as “=[Price] * 0.9” (assuming you want a 10% discount).
  7. Click “OK” to add the column.
  8. You can now see the new “Discounted Price” column in the Power Query Editor’s preview pane.
  9. Close the Power Query Editor and apply the changes.
  10. The updated report will now display the original price and the discounted price side by side.

Remember to save your report after making any changes.

Leave a comment