All Products
Search
Document Center

AnalyticDB:Metabase

Last Updated:Jun 05, 2026

Metabase is an open source business intelligence (BI) platform that supports multiple data sources, such as MySQL and PostgreSQL. It provides an intuitive web interface that allows users of different databases to easily explore and visualize their data. This topic shows you how to connect Metabase to AnalyticDB for MySQL.

Prerequisites

Connect to the AnalyticDB for MySQL endpoint

  1. In your AnalyticDB for MySQL cluster, run the following command to allow other data types to be converted to the UNSIGNED INTEGER type. This ensures that Metabase can correctly retrieve metadata.

    SET ADB_CONFIG O_UNSIGNED_AS_BIGINT_ENABLED=true;
  2. Go to the Metabase web interface. In the upper-right corner, click the gear icon (image) and select Admin settings from the drop-down menu.

    image

  3. In the top navigation bar, click Databases. On the Databases page, click Adding a Database.

    image

  4. Configure the following parameters and click Save.

    Parameter

    Description

    Database type

    Select MySQL from the drop-down list.

    Display name

    Enter a custom name for the data source.

    Host

    The endpoint of your AnalyticDB for MySQL cluster.

    • If Metabase is installed on an ECS instance, and the ECS instance and the AnalyticDB for MySQL cluster are in the same VPC, enter the internal endpoint.

    • If Metabase is installed on a local server, enter the public endpoint.

    Port

    The port number, fixed at 3306.

    Database name

    Enter the name of the database in your AnalyticDB for MySQL cluster.

    Username

    Enter the database account for your AnalyticDB for MySQL cluster.

    Password

    Enter the password for the database account of your AnalyticDB for MySQL cluster.

    Additional JDBC connection string options

    Enter tinyInt1isBit=false.

    Note

    Do not add spaces before or after the equal sign (=). Otherwise, you will be unable to visualize data after connecting to the AnalyticDB for MySQL cluster.

    Other parameters

    For information about other parameters, see the official Metabase documentation.

  5. After you complete the configuration, you can connect to AnalyticDB for MySQL and start data analysis. For more information about data analysis, see the official Metabase documentation.

    image

Connect to the Spark JDBC endpoint

  1. Go to the Metabase web interface. In the upper-right corner, click the gear icon (image) and select Admin settings from the drop-down menu.

    image

  2. In the top navigation bar, click Databases. On the Databases page, click Adding a Database.

    image

  3. Configure the following parameters and click Save.

    image

    Parameter

    Description

    Database type

    Select Spark SQL from the drop-down list.

    Display name

    Enter a custom name for the data source.

    Host

    Enter the endpoint of the Spark Interactive resource group. For more information, see View the endpoint and port of a resource group.

    Port

    The port number of the Spark Interactive resource group, fixed at 10000.

    Database name

    Enter the name of the database in your AnalyticDB for MySQL cluster.

    Username

    Enter the database account for your AnalyticDB for MySQL cluster.

    Password

    Enter the password for the database account of your AnalyticDB for MySQL cluster.

    Additional JDBC connection string options

    Enter ?resource_group=<your_resource_group_name>.

  4. After you complete the configuration, you can connect to AnalyticDB for MySQL and start data analysis. For more information about data analysis, see the official Metabase documentation.

    image