Power BI Desktop 中的数据源Data sources in Power BI Desktop

使用 Power BI Desktop,你可以连接到来自许多不同的源的数据。With Power BI Desktop, you can connect to data from many different sources. 在此页面底部列出了可用数据源的完整清单。A full list of available data sources is at the bottom of this page.

若要连接到数据,请在主页功能区中选择 获取数据To connect to data, select Get Data from the Home ribbon. 选择向下箭头,或按钮上的获取数据文本,将会显示如下图所示的最常见的数据类型菜单。Selecting the down arrow, or the Get Data text on the button, shows the Most Common data types menu shown in the following image.

最常见菜单选择Selecting More… 更多…将会显示获取数据窗口。from the Most Common menu displays the Get Data window. 你还可以通过直接选择获取数据图标按钮来打开获取数据窗口(绕过最常见菜单)。You can also bring up the Get Data window (and bypass the Most Common menu) by selecting the Get Data icon button directly.

备注

Power BI 团队正在不断扩展适用于 Power BI Desktop 和 Power BI 服务的数据源。The Power BI team is continually expanding the data sources available to Power BI Desktop and the Power BI service. 因此,你通常会看到工作过程中的数据源版本标记为 Beta预览As such, you'll often see early versions of work-in-progress data sources marked as Beta or Preview. 标记为 Beta预览的任何数据源所提供的支持和功能有限,不应在生产环境中使用。Any data source marked as Beta or Preview has limited support and functionality, and should not be used in production environments.

数据源Data Sources

数据类型分为以下类别:Data types are organized in the following categories:

  • 全部All
  • 文件File
  • 数据库Database
  • AzureAzure
  • Online ServicesOnline Services
  • 其他Other

全部类别包括来自所有类别的所有数据连接类型。The All category includes all data connection types from all categories.

文件类别提供下列数据连接:The File category provides the following data connections:

  • ExcelExcel
  • 文本/CSVText/CSV
  • XMLXML
  • JSONJSON
  • 文件夹Folder
  • SharePoint 文件夹SharePoint Folder

下图显示文件获取数据窗口。The following image shows the Get Data window for File.

备注

在旧版 Power BI Desktop 中,CSV 和文本为单独的数据连接类型。In previous versions of Power BI Desktop, CSV and Text were separate data connection types. 这些数据连接器已经并入 CSV/文本Those data connectors have been combined into CSV/Text.

数据库类别提供下列数据连接:The Database category provides the following data connections:

  • SQL Server 数据库SQL Server Database
  • Access 数据库Access Database
  • SQL Server Analysis Services 数据库SQL Server Analysis Services Database
  • Oracle 数据库Oracle Database
  • IBM DB2 数据库IBM DB2 Database
  • IBM Informix 数据库 (Beta)IBM Informix database (Beta)
  • IBM Netezza (Beta)IBM Netezza (Beta)
  • MySQL 数据库MySQL Database
  • PostgreSQL 数据库PostgreSQL Database
  • Sybase 数据库Sybase Database
  • Teradata 数据库Teradata Database
  • SAP HANA 数据库SAP HANA Database
  • SAP Business Warehouse 服务器SAP Business Warehouse server
  • Amazon RedshiftAmazon Redshift
  • ImpalaImpala
  • Google BigQuery (Beta)Google BigQuery (Beta)
  • SnowflakeSnowflake

备注

某些数据库连接器需要通过选择“文件”>“选项和设置”>“选项”,然后再选择“预览功能”才能启用。Some database connectors require that you enable them by selecting File > Options and settings > Options then selecting Preview Features and enabling the connector. 如果你没有看到上面提到的某些连接器,但想使用它们,请检查“预览功能”设置。If you don't see some of the connectors mentioned above and want to use them, check your Preview Features settings. 另请注意,标记为 Beta预览的任何数据源所提供的支持和功能有限,不应在生产环境中使用。Also note that any data source marked as Beta or Preview has limited support and functionality, and should not be used in production environments.

下图显示数据库获取数据窗口。The following image shows the Get Data window for Database.

Azure 类别提供下列数据连接:The Azure category provides the following data connections:

  • Azure SQL 数据库Azure SQL Database
  • Azure SQL 数据仓库Azure SQL Data Warehouse
  • Azure Analysis Services 数据库 (Beta)Azure Analysis Services database (Beta)
  • Azure Blob 存储Azure Blob Storage
  • Azure 表存储Azure Table Storage
  • Azure Cosmos DB (Beta)Azure Cosmos DB (Beta)
  • Azure Data Lake StoreAzure Data Lake Store
  • Azure HDInsight (HDFS)Azure HDInsight (HDFS)
  • Azure HDInsight Spark (Beta)Azure HDInsight Spark (Beta)

下图显示 Azure获取数据窗口。The following image shows the Get Data window for Azure.

Online Services 类别提供下列数据连接:The Online Services category provides the following data connections:

  • Power BI 服务Power BI service
  • SharePoint Online 列表SharePoint Online List
  • Microsoft Exchange OnlineMicrosoft Exchange Online
  • Dynamics 365(联机)Dynamics 365 (online)
  • Dynamics 365 for Financials (Beta)Dynamics 365 for Financials (Beta)
  • Common Data Service (Beta)Common Data Service (Beta)
  • Microsoft Azure 使用情况见解 (Beta)Microsoft Azure Consumption Insights (Beta)
  • Visual Studio Team Services (Beta)Visual Studio Team Services (Beta)
  • Salesforce 对象Salesforce Objects
  • Salesforce 报表Salesforce Reports
  • Google AnalyticsGoogle Analytics
  • appFigures (Beta)appFigures (Beta)
  • comScore Digital Analytix (Beta)comScore Digital Analytix (Beta)
  • Dynamics 365 for Customer Insights (Beta)Dynamics 365 for Customer Insights (Beta)
  • FacebookFacebook
  • GitHub (Beta)GitHub (Beta)
  • Kusto (Beta)Kusto (Beta)
  • MailChimp (Beta)MailChimp (Beta)
  • Mixpanel (Beta)Mixpanel (Beta)
  • Planview Enterprise (Beta)Planview Enterprise (Beta)
  • Projectplace (Beta)Projectplace (Beta)
  • QuickBooks Online (Beta)QuickBooks Online (Beta)
  • SmartsheetSmartsheet
  • SparkPost (Beta)SparkPost (Beta)
  • SQL Sentry (Beta)SQL Sentry (Beta)
  • Stripe (Beta)Stripe (Beta)
  • SweetIQ (Beta)SweetIQ (Beta)
  • Troux (Beta)Troux (Beta)
  • Twilio (Beta)Twilio (Beta)
  • tyGraph (Beta)tyGraph (Beta)
  • Webtrends (Beta)Webtrends (Beta)
  • Zendesk (Beta)Zendesk (Beta)

下图显示 Online Services获取数据窗口。The following image shows the Get Data window for Online Services.

其他类别提供下列数据连接:The Other category provides the following data connections:

  • Vertica (Beta)Vertica (Beta)
  • WebWeb
  • SharePoint 列表SharePoint List
  • OData 数据源OData Feed
  • Active DirectoryActive Directory
  • Microsoft ExchangeMicrosoft Exchange
  • Hadoop 文件 (HDFS)Hadoop File (HDFS)
  • Spark (Beta)Spark (Beta)
  • R 脚本R Script
  • ODBCODBC
  • OLE DBOLE DB
  • 空查询Blank Query

下图显示其他获取数据窗口。The following image shows the Get Data window for Other.

备注

此时,无法连接到使用 Azure Active Directory 保护的自定义数据源。At this time, it's not possible to connect to custom data sources secured using Azure Active Directory.

连接到数据源Connecting to a Data Source

若要连接到数据源,请从获取数据窗口选择数据源,然后选择连接To connect to a data source, select the data source from the Get Data window and select Connect. 在下图中,已从其他数据连接类别中选择了 WebIn the following image, Web is selected from the Other data connection category.

将显示特定于数据连接类型的连接窗口。A connection window is displayed, specific to the type of data connection. 如果需要提供凭据,将提示你提供凭据。If credentials are required, you’ll be prompted to provide them. 下图显示输入 URL 以便连接到 Web 数据源。The following image shows a URL being entered to connect to a Web data source.

输入 URL 或资源连接信息后,选择确定When the URL or resource connection information is entered, select OK. Power BI Desktop 会建立到数据源的连接,并在导航器中显示可用的数据源。Power BI Desktop makes the connection to the data source, and presents the available data sources in the Navigator.

可以通过选择导航器窗格底部的加载按钮加载数据,或者选择编辑按钮,在加载数据之前编辑查询。You can either load the data by selecting the Load button at the bottom of the Navigator pane, or edit the query before loading data by selecting the Edit button.

这就是连接到 Power BI Desktop 中的数据源的所有相关信息!That’s all there is to connecting to data sources in Power BI Desktop! 尝试从我们不断增多的数据源列表连接到数据,并经常回访 - 我们会持续将数据源添加到此列表中。Try connecting to data from our growing list of data sources, and check back often - we continue to add to this list all the time.

后续步骤Next steps

Power BI Desktop 可用于执行多种操作。There are all sorts of things you can do with Power BI Desktop. 有关其功能的详细信息,请参阅下列资源:For more information on its capabilities, check out the following resources: