This topic describes how to use QlikView to connect to an AnalyticDB for MySQL cluster and build a business intelligence (BI) system.
- The MySQL Open Database Connectivity (ODBC) driver is installed. We recommend that you use MySQL Connector/ODBC 3.5.1 or 5.3.
- QlikView 11.20.x is installed.
Use QlikView to connect to an AnalyticDB for MySQL cluster
- On the host where QlikView is installed, choose MySQL ODBC 5.xx Driver as the data source.. This path may vary with the operating system. In the ODBC Data Source Administrator
dialog box that appears, add a system data source name (DSN) and select
Parameter Description Data Source Name The name of the database in the AnalyticDB for MySQL cluster. TCP/IP Server The endpoint of the AnalyticDB for MySQL cluster to which you want to connect. Port The port number of the AnalyticDB for MySQL cluster endpoint. User The account used to connect to the AnalyticDB for MySQL cluster. You can use one of the following account types:
- Privileged account
- Standard account
Password The password of the account used to connect to the AnalyticDB for MySQL cluster.
- After you configure the preceding parameters, click Test to test the connectivity. After the connection passes the test, click OK to connect to the AnalyticDB for MySQL database.
- Start QlikView and choose . Select the database name specified in Step 1 to test the connectivity.Note You can also execute the
ODBC CONNECT TO DATABASE_NAME;statement to test the connectivity.
- After the database passes the connectivity test, use the following SELECT statement
to obtain data from the AnalyticDB for MySQL cluster:
SELECT * FROM DATABASE_NAME.TABLE_NAME;
For example, use the following statement to obtain data from the user_info table:
SELECT * FROM adb_database.user_info;
After you obtain data from AnalyticDB for MySQL databases, you can use QlikView to perform more operations. For more information about how to use QlikView, visit QlikView.