Help Center/ AI DataLake/ Best Practices/ Connecting BI Tools to AI DataLake Spark for Data Analysis/ Connecting FineBI to AI DataLake Spark for Data Query and Analysis
Updated on 2026-11-06 GMT+08:00

Connecting FineBI to AI DataLake Spark for Data Query and Analysis

FineBI is an intelligent, visual tool that focuses on data analysis and visualization. It can connect to various data sources and transform intricate data into intuitive charts and dashboards to swiftly gain data insights.

This section describes how to configure FineBI to connect to AI DataLake to access and analyze data in AI DataLake.

Preparations

Step 1: Install FineBI and Configure Data Connections

  1. Download and install FineBI.

    1. Download the FineBI installation package.
    2. Find the downloaded FineBI installation program file.
    3. Double-click the installation program.
    4. Follow the installation wizard to perform installation operations, including accepting the license agreement, selecting the installation type (typical or custom), and setting the installation directory.

  2. Configure FineBI to support custom drivers.

    1. Open the script for editing custom drivers.

      Locate the edit script /webapps/webroot/WEB-INF/embed/finedb/db.script in the root directory of FineBI installation.

    2. Add the following content to the script:
      INSERT INTO FINE_CONF_ENTITY VALUES('SystemConfig.driverUpload','true')

      If the file already contains the SystemConfig.driverUpload parameter, change its value from false to true.

    3. Restart FineBI for the modifications to take effect.

  3. Integrate the JDBC driver with FineBI.

    1. Download the data driver.

      Click aidatalake-spark-jdbc-x.x.x.jar to obtain the JDBC driver.

    2. Obtain Log4j JAR files.

      Download the following Log4j dependency packages from the official Maven repository:

      • log4j-api-2.xx.jar
      • log4j-core-2.xx.jar
      • log4j-slf4j-impl-2.xx.jar
    3. Integrate the AI DataLake driver into FineBI.
      1. Open FineBI.
      2. Choose Data Connection > Data Connection Management.
      3. Click Create. On the displayed page, select the AI DataLake JDBC driver from the Driver drop-down list box and click Upload File to upload Log4j JAR files.
        Figure 1 Installing a data connection driver for FineBI

  4. Configure a database connection.

    1. Choose Data Connection > Data Connection Management.
    2. Click Create and then Other JDBC.
      Figure 2 Clicking Other JDBC
    3. Set connection parameters.
      Figure 3 Setting connection parameters
      Table 1 Parameters for connecting FineBI to AI DataLake

      Parameter

      Description

      Username

      Username used to log in to the server. Enter the AK of the Huawei Cloud account.

      For details about how to obtain the AK and SK, see AK/SK Obtaining.

      Password

      Password used to log in to the server. Enter the SK of the Huawei Cloud account.

      For details about how to obtain the AK and SK, see AK/SK Obtaining.

      Encoding

      Mode in which FineBI interacts with the target database.

      Select UTF-8.

      Data Connection URL

      JDBC connection string The format is as follows:

      jdbc:aidatalakespark://{endpointName}/{ProjectID}?aidatalake.workspaceId={workspaceId}&lakeformation.instanceId={lakeformationInstanceId}&endpointname={AIDataLake Spark Endpoint}&regionName={regionName}&catalog={catalogName}&obs.endpoint={ObsEndPoint}&fineBIDialect=CustomSparkDialect

      The following table lists the parameters of the JDBC connection string.

      Table 2 Parameters of the JDBC connection string

      Parameter

      Description

      Example Value

      endpointName

      URL of the AI DataLake service

      An endpoint is the request address for calling an API. Endpoints vary depending on services and regions. For the endpoints of all services, see Regions and Endpoints.

      https://aidatalake-test.cn-north-7.myhuaweicloud.com

      ProjectID

      AI DataLake project ID

      Hover the cursor over the account information in the upper right corner of the AI DataLake console, click My Credentials, and obtain the project ID.

      0b33ea2a7e******4c009bb05076d

      workspaceId

      AI DataLake workspace ID

      Log in to the AI DataLake console and find the target workspace ID on the workspace management page.

      spark

      lakeformationInstanceId

      LakeFormation instance ID

      For how to obtain the ID, see

      How Do I Obtain the ID of a LakeFormation Instance?

      ae6dd098-***-*****-c02***def36d

      regionName

      Region name of AI DataLake

      cn-north-7

      catalogName

      Data catalog name

      • This parameter is mandatory when a LakeFormation catalog is used. Set it to the corresponding LakeFormation catalog name.

        When querying a LakeFormation catalog, ensure that there is a default database in the catalog.

      • If this parameter is not specified, an AI DataLake catalog is used. You do not need to configure this parameter when an AI DataLake catalog is used.

      For example, if a LakeFormation catalog named lfcatalog is used, the configuration is as follows: catalog=lfcatalog.

      ObsEndPoint

      OBS endpoint

      For how to obtain it, see Endpoints and Domain Names.

      -

    4. Click Save.

Step 2: Create a Custom SQL Query

  1. Choose Public Data. Click Add Dataset and select SQL Dataset.
    Figure 4 Opening a data connection
  2. Select Data from Data Connection.
  3. Enter a custom SQL query statement to start data analysis.
    Figure 5 Custom SQL query statement