Visualize data with Power BI
In this tutorial, you'll learn how to create a Power BI workspace, link your Azure Synapse workspace, and create a Power BI data set that utilizes data in your Azure Synapse workspace.
Prerequisites
To complete this tutorial, install Power BI Desktop.
Overview
From the NYC Taxi data, we created aggregated datasets in two tables:
- nyctaxi.passengercountstats
- SQLDB1.dbo.PassengerCountStats
You can link a Power BI workspace to your Azure Synapse workspace. This capability allows you to easily get data into your Power BI workspace. You can edit your Power BI reports directly in your Azure Synapse workspace.
Create a Power BI workspace
- Sign in to powerbi.microsoft.com.
- Click on Workspaces, then select Create a workspace. Create a new Power BI workspace named NYCTaxiWorkspace1 or similar, since this name must be unique.
Link your Azure Synapse workspace to your new Power BI workspace
- In Synapse Studio, go to Manage > Linked Services.
- Select New > Connect to Power BI.
- Set Name to NYCTaxiWorkspace1.
- Set Workspace name to the Power BI workspace you created above, similar to NYCTaxiWorkspace1.
- Select Create.
Create a Power BI dataset that uses data in your Azure Synapse workspace
- In Synapse Studio, go to Develop > Power BI.
- Go to NYCTaxiWorkspace1 > Power BI datasets and select New Power BI dataset. Click Start.
- Select the SQLPOOL1 data source, click Continue.
- Click Download to download the .pbids file for your NYCTaxiWorkspace1SQLPOOL1.pbids file. Click Continue.
- Open the downloaded .pbids file. Power BI Desktop opens and automatically connects to SQLDB1 in your Azure Synapse workspace.
- If you see a dialog box appear called SQL Server database:
- Select Microsoft account.
- Select Sign in and sign in to your account.
- Select Connect.
- After the Navigator dialog box opens, check the PassengerCountStats table and select Load.
- After the Connection settings dialog box appears, select DirectQuery > OK.
- Select the Report button on the left side.
- Under Visualizations, click to the line chart icon to add a Line chart to your report.
- Under Fields, drag the PassengerCount column to Visualizations > Axis.
- Drag the SumTripDistance and AvgTripDistance columns to Visualizations > Values.
- On the Home tab, select Publish.
- Select Save to save your changes.
- Choose the file name PassengerAnalysis.pbix, and then select Save.
- In the Publish to Power BI window, under Select a destination, choose your NYCTaxiWorkspace1, and then click Select.
- Wait for publishing to finish.
Configure authentication for your dataset
- Open powerbi.microsoft.com and Sign in.
- On the left side, under Workspaces, select the NYCTaxiWorkspace1 workspace.
- Inside that workspace, locate a dataset called Passenger Analysis and a report called Passenger Analysis.
- Hover over the PassengerAnalysis dataset, select the ellipsis (...) button, and then select Settings.
- In Data source credentials, click Edit, set the Authentication method to OAuth2, and then select Sign in.
Edit a report in Synapse Studio
- Go back to Synapse Studio and select Close and refresh.
- Go to the Develop hub.
- To the right of the Power BI layer, ellipsis (...) button, and click refresh to refresh the Power BI reports node.
- Under Power BI you should see:
- In NYCTaxiWorkspace1 > Power BI datasets, a new dataset called PassengerAnalysis.
- Under NYCTaxiWorkspace1 > Power BI reports, a new report called PassengerAnalysis.
- Select the PassengerAnalysis report. The report opens and you can edit it directly within Synapse Studio.
Next steps
Feedback
Submit and view feedback for