diff --git a/pages/data-warehouse/how-to/connect-bi-tools.mdx b/pages/data-warehouse/how-to/connect-bi-tools.mdx index 6cae4fb498..5c251f24b5 100644 --- a/pages/data-warehouse/how-to/connect-bi-tools.mdx +++ b/pages/data-warehouse/how-to/connect-bi-tools.mdx @@ -110,34 +110,75 @@ Refer to the official [ClickHouse®](https://clickhouse.com/docs/integrations/me ## PowerBI Desktop -Power BI Desktop is a robust data visualization tool that allows users to create dynamic reports and dashboards from various data sources. +Power BI Desktop is a robust data visualization tool that allows users to create dynamic reports and dashboards from various data sources. To connect to your Data Warehouse for ClickHouse® deployment, PowerBI requires a MySQL connection using a dedicated user with a **plain text password**. ODBC connection between PowerBI and Data Warehouse for ClickHouse® is currently not supported. +### Creating a dedicated MySQL user -0. Make sure you installed [PowerBI Desktop]https://www.microsoft.com/en-us/download/details.aspx?id=58494/), and [MySQL Connector/NET](https://dev.mysql.com/downloads/connector/net/). +1. [Connect to your deployment](/data-warehouse/how-to/connect-applications/). -1. Open PowerBI Desktop. +2. Run the SQL query below to create a user with a plain text password. Replace the placeholders with the appropriate values: + ```sql + CREATE USER mysql_user IDENTIFIED WITH plaintext_password BY 'mysql_user_password'; + ``` -2. Click **Get Data** from the top ribbon, then select **More...** at the bottom of the drop-down menu. A pop-up displays. +3. Run the SQL query below to grant the user access to the database: -3. Select the **Database** category, select **MySQL database** in the list, then click **Connect**. A connection pop-up displays. + ```sql + GRANT SELECT(id) ON my_database.my_table TO mysql_user WITH GRANT OPTION; + ``` -4. Enter the values below, then click **OK**. +Your user can now access the specified database using the credentials you just defined. + +### Connecting PowerBI to your deployment + + + +1. Make sure you installed [PowerBI Desktop](https://www.microsoft.com/en-us/download/details.aspx?id=58494/), and [MySQL Connector/NET](https://dev.mysql.com/downloads/connector/net/). + +2. Open PowerBI Desktop. + +3. Click **Get Data** from the top ribbon, then select **More...** at the bottom of the drop-down menu. A pop-up displays. + +4. Select the **Database** category, select **MySQL database** in the list, then click **Connect**. A connection pop-up displays. + +5. Enter the values below, then click **OK**. - **Server**: `.dtwh..scw.cloud` - **Database**: the name of the database to import A credentials pop-up displays. -5. Select **Database** from the left menu, enter the values below, then click **Connect**. - - **User name**: your deployment admin user (`scwadmin` by default) +6. Select **Database** from the left menu, enter the values below, then click **Connect**. + - **User name**: your dedicated MySQL user [previously created](#creating-a-dedicated-mysql-user) - **Password**: the password you set at deployment creation The **Navigator** pop-up displays, showing the different schemas and tables contained in your Data Warehouse for ClickHouse® deployment. -6. Select the desired tables, then **Load** to import data, or **Transform Data** to start working with your dataset. +7. Select the desired tables, then **Load** to import data, or **Transform Data** to start working with your dataset. + + + +1. Access [PowerBI Service](https://app.powerbi.com). + +2. From the PowerBI Service interface, click the **+ New** button from the toolbar. A list of data sources displays. + +3. Select **MySQL Database** from the list. A connection wizard displays. + +4. Enter the following values. + - **Server**: `.dtwh..scw.cloud` + - **Database**: the name of the database to import (`default` if you did not create additional databases in your deployment) + - **Connection**: `.dtwh..scw.cloud` + - **Connection name**: `.dtwh..scw.cloud` + - Authentication type: `Basic` + - Username: your dedicated MySQL user [previously created](#creating-a-dedicated-mysql-user)) + - Password: The plain text password assigned to your MySQL user + - Privacy level: `None` +5. Click **Next**. The **Power Query** interface displays, allowing you to use the `MySQL.Database` function from this interface. + + Your Data Warehouse for ClickHouse® is now integrated into your PowerBI platform.