163|POWERBI – Peaks Cycles, Relationships and Paths

BYU Student Author: @Jacob_Dutton
Reviewers: @Jimmy_Han, @James_Gerstner
Estimated Time to Solve: 10 Minutes

This is an intro challenge that is part of the PowerBI Learning Path.

We provide the solution to this challenge using:

  • Power BI

Need a program? Click here.

You’ve just landed the role of Financial Analyst at Peak Cycles, a bustling bike shop known for its quality and variety. Your first task is a vital one: Fix the data connections and relationships between tables in your company’s Power BI file.

Your Tasks:
Download: Download the Power BI template and data files.
Fix Paths: Change the paths to the data file in Power Query to wherever you stored your data file.
Fix Relationships: Create relationships between the different tables from the dataset. Relationships help to connect different tables together using matching columns called “keys.

Download Files and Fix Paths

  1. Download Files: Download the data file and Power BI template.
  2. Open Power Query: Click on the “Transform Data” button to open Power Query.
  3. Fix paths: On the left side of Power Query you will see each query. On the right side you will see each step of the query. Navigate to the first step in each query, and replace the broken path with the path of the data file you downloaded.
  4. Close and Load: Click the “Home” tab and “Close and Load.

Fix Relationships

  1. Open Model View: Select Model view from the left pane.
  2. Manage Relationships: Select Manage Relationships from the top pane.
  3. Create Relationships:
    • Select the New.
    • Select Bike_Export as your top table, and Invoice_Export as your bottom table.
    • Select BikeID in both tables.
    • Choose One to many for your cardinality and leave all other settings in their defaults.
    • Select "Ok”
    • Repeat for Customer_Info and Invoice_Export, selecting the CustomerID columns instead.

Final Steps
Now that your paths and relationships are fixed, you are ready to select the refresh button in the header!

Data Files

Suggestions and Hints

Make sure to select close and apply after doing your data cleaning in Power Query.