在 Power BI Desktop 中连接到 SnowflakeConnect to Snowflake in Power BI Desktop

在 Power BI Desktop 中,你可以连接到 Snowflake 计算仓库,并可如同使用 Power BI Desktop 中任何其他数据源一样使用基础数据。In Power BI Desktop, you can connect to a Snowflake computing warehouse and use the underlying data just like any other data source in Power BI Desktop.

备注

此外,在使用 Snowflake 连接器的计算机上,你必须使用匹配 Power BI Desktop 32 位或 64 位安装的体系结构安装 Snowflake ODBC 驱动程序You also must install the Snowflake ODBC driver on computers that use the Snowflake connector, using the architecture that matches the installation of Power BI Desktop, either 32-bit or 64-bit. 只需按照以下链接操作,并下载合适的 Snowflake ODBC 驱动程序Just follow the following link and download the appropriate Snowflake ODBC driver.

连接到 Snowflake 计算仓库Connect to a Snowflake computing warehouse

若要连接到 Snowflake 计算仓库,请从 Power BI Desktop 中的“开始”功能区选择“获取数据”。To connect to a Snowflake computing warehouse select Get Data from the Home ribbon in Power BI Desktop. 选择左侧类别中的“数据库”,然后便会看到“Snowflake”。Select Database from the categories on the left, and you see Snowflake.

在出现的 Snowflake 窗口中,将你的 Snowflake 计算仓库名称键入或粘贴到框中,然后选择“确定”。In the Snowflake window that appears, type or paste the name of your Snowflake computing warehouse into the box and select OK. 请注意,可以选择将数据直接导入到 Power BI 中,或使用 DirectQueryNote that you can choose to Import data directly into Power BI, or you can use DirectQuery. 可以了解有关使用 DirectQuery 的详细信息。You can learn more about using DirectQuery.

出现提示时,输入你的用户名和密码。When prompted, put in your username and password.

备注

一旦输入用户名和密码以连接特定 Snowflake 服务器,Power BI Desktop 在后续连接尝试中就会使用这些凭据。Once you put in your username and password for a particular Snowflake server, Power BI Desktop uses those same credentials in subsequent connection attempts. 可以通过“文件”>“选项和设置”>“数据源设置”来修改这些凭据。You can modify those credentials by going to File > Options and settings > Data source settings.

连接成功后,将会出现“导航器”窗口,并显示服务器上可用的数据。你可以从这些数据中选择要在 Power BI Desktop 中导入和使用的一个或多个元素。Once you successfully connect, a Navigator window appears and displays the data available on the server, from which you can select one or multiple elements to import and use in Power BI Desktop.

你可以加载选定的表,该操作将把整个表格加载到 Power BI Desktop中,或者你也可以编辑查询,这将打开查询编辑器,以便筛选和优化要使用的数据集,然后将优化后的数据集加载到 Power BI Desktop 中。You can Load the selected table, which brings the entire table into Power BI Desktop, or you can Edit the query, which opens Query Editor so you can filter and refine the set of data you want to use, and then load that refined set of data into Power BI Desktop.

后续步骤Next steps

你可以使用 Power BI Desktop 连接到各种数据。There are all sorts of data you can connect to using Power BI Desktop. 有关数据源的详细信息,请参阅下列资源:For more information on data sources, check out the following resources: