Multiplication:
1. Load your data:
Import your dataset into Power BI.
2. Open Power Query Editor:
Go to the "Home" tab and click on "Transform Data" to open the Power Query Editor.
3. Select Columns:
In the Power Query Editor, select the two columns you want to multiply.
4. Add Custom Column:
Go to the "Add Column" tab.
Click on "Standard" and then select "Multiply".
This will create a new column with the product of the two selected columns.
5. Rename the New Column:
You can rename the new column to something more meaningful by right-clicking on the column header and selecting "Rename".
6. Close and Apply:
Once you have added the new column, click on "Close & Apply" to apply the changes and return to the main Power BI window.
You should now have a new column with the product of the two selected columns in your dataset.
Tip
If you try to multiply 3 columns from our dataset (Quantity, Discount, Profit) you will get answer as "0 (zero)" in many columns. This is because anything multiplyed by "0" will give answer as "0". To correct this follow these steps
1. When you multiply 3 columns you will get a new column showing result for multiplication
2. Go to "Applied Steps" section on the right hand side of the screen
3. Click the small "Settings Button" next to the heading "Inserted Multiplication"
4. A dialogue box will appear (Formula Bar)
5. Under custom column formula you will find following formula " =List.Product({[Sales], [Quantity], [Discount]})"
6. Change this formula as under
7. = List.Product({[Sales], [Quantity], (1 - [Discount])}) and click on "OK"
8. Now you will be able to see the correct multiplication in the resultant column
Addition:
1. Load your data:
Import your dataset into Power BI.
2. Open Power Query Editor:
Go to the "Home" tab and click on "Transform Data" to open the Power Query Editor.
3. Select Columns:
In the Power Query Editor, select the two columns you want to add.
4. Add Custom Column:
Go to the "Add Column" tab.
Click on "Standard" and then select "Add".
This will create a new column with the sum of the two selected columns.
5. Rename the New Column:
You can rename the new column to something more meaningful by right-clicking on the column header and selecting "Rename".
6. Close and Apply:
Once you have added the new column, click on "Close & Apply" to apply the changes and return to the main Power BI window.
You should now have a new column with the sum of the two selected columns in your dataset.
Subtraction:
1. Load your data:
Import your dataset into Power BI.
2. Open Power Query Editor:
Go to the "Home" tab and click on "Transform Data" to open the Power Query Editor.
3. Select Columns:
In the Power Query Editor, select the two columns you want to subtract.
4. Add Custom Column:
Go to the "Add Column" tab.
Click on "Standard" and then select "Subtract".
This will create a new column with the difference between the two selected columns.
5. Rename the New Column:
You can rename the new column to something more meaningful by right-clicking on the column header and selecting "Rename".
6. Close and Apply:
Once you have added the new column, click on "Close & Apply" to apply the changes and return to the main Power BI window.
You should now have a new column with the difference between the two selected columns in your dataset
Division:
1. Load your data:
Import your dataset into Power BI.
2. Open Power Query Editor:
Go to the "Home" tab and click on "Transform Data" to open the Power Query Editor.
3. Select Columns:
In the Power Query Editor, select the two columns you want to divide.
4. Add Custom Column:
Go to the "Add Column" tab.
Click on "Standard" and then select "Divide".
This will create a new column with the result of dividing the first selected column by the second selected column.
5. Rename the New Column:
You can rename the new column to something more meaningful by right-clicking on the column header and selecting "Rename".
6. Close and Apply:
Once you have added the new column, click on "Close & Apply" to apply the changes and return to the main Power BI window.
You should now have a new column with the result of dividing the two selected columns in your dataset.