Connecting to TiDB
Connection Steps
Please follow the steps below to connect to the TiDB
data source.
Click "New Data Connection" in the upper right corner of the data connection page.
Select the
TiDB
data source from the data source types.Fill in the required parameters for the data source connection as prompted.
Connection Configuration Information Description
Field Description Name The name of the connection. Required and unique within the user. Host Address The address of the database. If the URL field is filled, the URL takes precedence. Port The port of the database. If the URL field is filled, the URL takes precedence. Username The username for the database. Password The password for the database. Database The name of the database. Max Connections The maximum number of connections in the connection pool. Prefer to use database comment as dataset title Choose whether to display the table name or the table comment. When enabled, the title is displayed; when disabled, the table comment is displayed. URL The JDBC URL of the database. Hierarchical loading of schema and tables Default is off. When enabled, schemas and tables are loaded hierarchically. Only schemas are loaded during connection, and you need to click the schema to load the tables under it. Query Timeout (seconds) Default is 600. If the data volume is large, you can increase the timeout as appropriate. Only show tables under the specified database/schema When this option is selected and the database field is not empty, only tables under the specified database will be displayed. After filling in the parameters, click the
Validate
button to get the validation result (this checks the connectivity between HENGSHI SENSE and the configured data connection; you cannot add the connection if validation fails).After validation passes, click
Execute Preset Code
to pop up the preset code for this data source, then click the execute button.Click the
Add
button to add theTiDB
connection.
Please Note
- Parameters marked with * are required; others are optional.
- TiDB does not support window functions, so it does not support Advanced Calculation. You must enable the Acceleration Engine for support.
- When connecting to a data source, you must execute the preset code. Failure to do so will result in some functions being unavailable during data analysis. In addition, when upgrading from a version prior to 4.4 to 4.4, you need to execute the preset code for existing data connections in the system.
Supported TiDB
Versions
v2.0
, v2.1
, v3.0
, v3.1
, v4.0
, v5.0
, v5.1
, v5.3
, v6.0
, v6.2
, v6.3
, v6.4
, v6.6
, v7.0
, v7.2
, v7.3
, v7.4
, v7.6
, v8.0
, v8.2
, v8.3
, v8.4
Data Connection Preview Support
Supports regular table
and view
as well as other tables that can be listed by show tables
.
SQL Dataset Support for SQL
All SELECT
-related features are supported. The SELECT SQL
statement must comply with the TiDB
syntax specification.