Data Source Credentials and Refresh
Learn how to configure data source credentials, understand privacy levels, refresh imported data, review refresh history, and troubleshoot common data access problems in Power BI.
1. What Are Data Source Credentials?
Data source credentials are authentication details that Power BI uses to access a data source. Depending on the source, authentication may use an organizational account, a username and password, an API key, or anonymous access.
Why Credentials Matter
- They allow authorized access to protected data.
- They help Power BI retrieve data during refresh operations.
- They control which account is used to connect to a source.
- They help organizations apply access and security policies.
Visual 1: Power BI authenticates with a source before accessing protected data.
2. Configuring Credentials in Power BI Desktop
Power BI Desktop may prompt you for authentication when you connect to a data source. You can also review saved source permissions through the application's data source settings.
Steps to Manage Credentials
- Open Power BI Desktop.
- Select File → Options and settings → Data source settings.
- Select the relevant data source from the list.
- Choose the available option to edit permissions or clear permissions.
- If needed, reconnect and select the correct authentication method.
- Enter the required credentials and test the connection.
- Refresh the data to verify that access works.
Common Authentication Methods
| Method | Typical Use | Consideration |
|---|---|---|
| Anonymous | Public sources without sign-in requirements | Use only when the source permits public access. |
| Organizational account | Supported work or school services | The account must have permission to access the resource. |
| Basic | Sources that support a username and password | Follow the source provider's security requirements. |
| Web API | Supported API key authentication | Protect keys and follow the API provider's instructions. |
3. Understanding Data Privacy Levels
Privacy levels help Power Query determine how data from different sources may be combined. They are particularly important when a query uses information from more than one source.
| Privacy Level | Description | Example |
|---|---|---|
| Public | Data intended to be shared publicly | A public reference dataset. |
| Organizational | Data intended to be shared within an organization | An approved internal reporting source. |
| Private | Sensitive data that should be isolated from other sources | A personal or confidential business dataset. |
The correct setting depends on the source's sensitivity and your organization's policies. Privacy levels are not a replacement for source permissions, access controls, or appropriate data handling.
Visual 2: Privacy levels classify sources according to their intended use and sensitivity.
4. What Is Data Refresh?
Data refresh retrieves updated data from the connected sources and updates the imported data in the Power BI semantic model when the refresh completes successfully.
Types of Data Updates
- Manual refresh: Start a refresh when needed.
- Scheduled refresh: Configure supported refresh times in the Power BI Service.
- DirectQuery: Queries the underlying source when data is requested, subject to the connector and model behavior.
- Automatic page refresh: Available for supported scenarios and configurations; it is not the same as refreshing imported model data.
Visual 3: Imported model data can be refreshed manually or through a configured schedule.
5. Configure Scheduled Refresh in the Power BI Service
After publishing a report, the semantic model may require credentials and refresh settings to be configured in the Power BI Service.
Typical Configuration Steps
- Publish the report from Power BI Desktop.
- Open the relevant workspace in the Power BI Service.
- Locate the semantic model associated with the report.
- Open its settings.
- Review data source credentials and connection settings.
- Configure supported credentials and any required gateway connection.
- Open the refresh section and enable a schedule if available.
- Select suitable refresh times and apply the configuration.
- Run or wait for a refresh, then review the result.
6. Understanding Gateway Requirements
A data gateway may be needed when the Power BI Service must reach a data source that is available only within a private network or on a local computer. Some cloud sources can be accessed directly without an on-premises gateway.
When a Gateway May Be Required
- The data source is hosted on an internal company network.
- The source is a local server that the Power BI Service cannot access directly.
- The connector or connection setup requires a gateway.
- The gateway must be online and configured with appropriate source credentials.
Visual 4: A gateway can provide a configured route between the cloud service and an internal data source.
7. Reviewing Refresh History
Refresh history helps identify whether a refresh succeeded, failed, or took longer than expected. When an error occurs, review the displayed details before changing the connection.
| Refresh Status | Possible Meaning | Recommended Action |
|---|---|---|
| Completed | The refresh finished successfully. | Confirm that the expected data is available. |
| Failed | The refresh encountered an error. | Read the error details and check access, credentials, and source availability. |
| Long-running | The source or query may be slow. | Review query efficiency, source performance, and response size. |
| Credentials error | Authentication may be missing or expired. | Update the supported credentials and retry. |
| Gateway error | The gateway may be unavailable or misconfigured. | Check gateway status, mapping, and permissions. |
8. Common Problems and Solutions
Problem: Credentials Are Rejected
Verify the authentication method, account permissions, and whether the credentials have expired. Confirm that the correct data source is selected in the settings.
Problem: Refresh Works in Desktop but Fails Online
Check the semantic model's service credentials, gateway requirements, source accessibility, and supported connector behavior. Desktop access does not automatically configure service refresh.
Problem: Refresh Is Slow
Review Power Query steps, the amount of data retrieved, network performance, source response times, and query folding where supported.
Problem: Some Rows Are Missing
Check source filters, API pagination, date ranges, permissions, and query steps that may remove records.
9. Practical Exercise
Exercise: Configure and Verify Refresh
Scenario: A report imports monthly sales data and must remain up to date.
- Open a Power BI Desktop report connected to an available practice data source.
- Review Data source settings and identify the authentication method.
- Verify that the source credentials work.
- Review the privacy level and select the appropriate setting for the source.
- Refresh the data in Power BI Desktop.
- Publish the report to a workspace where you have permission.
- Review the semantic model settings in the Power BI Service.
- Configure supported credentials and gateway settings if required.
- Set a refresh schedule if the workspace and model support it.
- Review refresh history and record the result.
Expected outcome: A report with verified source access and a documented refresh configuration.
10. Knowledge Check
Question 1: What is the main purpose of data source credentials?
A. To format charts
B. To authenticate access to a data source
C. To change report themes
D. To create relationships automatically
Question 2: What do privacy levels help Power Query manage?
A. Chart colors
B. Page size
C. How data from different sources may be combined
D. Font styles
Question 3: Why might a gateway be required?
A. To create a title
B. To access a supported internal data source from the Power BI Service
C. To format a table
D. To rename a measure
Question 4: Where can you investigate a failed service refresh?
A. The report theme gallery
B. The visual formatting pane
C. The semantic model refresh history and error details
D. The page navigation menu
View Answers
- B — To authenticate access to a data source.
- C — How data from different sources may be combined.
- B — To access a supported internal data source from the Power BI Service.
- C — The semantic model refresh history and error details.
Summary
In this lesson, you learned how Power BI uses data source credentials to authenticate access, how to manage authentication settings, and how privacy levels help control the combination of data from different sources.
You also explored manual and scheduled refresh, gateway requirements, refresh history, and common troubleshooting techniques for keeping reports up to date.