eFactoryPro Wiki

10.8 Power BI Content Creator: Create a Version Table in Power Query

Updated on

Create a Version Table in Power Query where you can keep track of version changes.

1. Open the PBIX file.

2. Click on Transform Data to open the Power Query Editor. Then click Enter Data.

3. Enter the Table Name as: Version_UpdateInSourceStep.

4. Double click on Column 1 header to update its name to Version Number.

5. Click the + sign to add a second column and change its name to Version Publish Date.

6. Click the + sign to add a third column and change its name to Version Note.

7. Enter data into row 1 for Version Number, Version Publish Date, and Version Note.

8. Click Load.

9. Verify Columns types as follows: Version Number is number, Version Publish Date is date, and Version Note is text.

10. Click the Add Column tab, then click the Custom Column button.

11. Enter New Column Name: Report Version.

12. Enter the following code for Custom column formula:

if Date.From(List.Max(#"Changed Type"[Version Publish Date])) = [Version Publish Date] then "v"& Number.ToText([Version Number]) else null

13. Click OK when done.

14. Go to the Home Menu and hit Close & Apply for the changes to take effect.

15. To add the version to the report in a visual:

15.1. Add a Card visual to the canvas.

15.2. Add the field Report Version to the card.

15.3. Display the options of the Report Version field in the Visualizations pane to select "Last" from the dropdown.

15.4. Using the Format option, update Data Label to a text size and color that matches your title or subtitle.

16. To update the version table:

16.1. Click on Transform Data to open the Power Query Editor.

16.2. Select the version table from the Queries pane.

16.3. In the Applied Steps pane, click on the gear next to Source

16.4. Click the + sign below row 1 to add a new row

16.5. Double click each column to enter data. Click OK when done.

16.6. Go to the Home Menu and hit Close & Apply for the changes to take effect.

16.7. The version in the Card will automatically update as the last input was selected in step 15.3

0 Comments

Add your comment

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Previous Article 10.7 How Do I Set Up Email Alerts in Power BI?
Next Article 10.9 Power BI Content Creator: Add Row Level Security with Permissions Table