Connection Method | Description |
Connecting to instances via DMC is easy. DMC provides database management services that integrate database/table-level operations, real-time monitoring, instance session management, SQL window, and data management. Note: Only the new version of DMC supports accessing read-only analysis engines. For the login address of the new version of DMC, go to the login page. | |
Cloud Virtual Machine (CVM) can be used to connect to databases via the private network address of TencentDB for MySQL. | |
CVM or third-party applications can be used to connect to databases via the public network address of TencentDB for MySQL. |
/* to server instance ID */ syntax in Hint Syntax Usage./*to ap*/ Hint syntax. If there are multiple read-only analysis engine instances, load balancing will be performed for SQL statements according to the weight of read-only analysis engines./*to server instance ID*/ syntax and the /*to ap*/ syntax does not exist, SQL statements will be forwarded to an existing read-only instance or the read-write instance in the database proxy by default for execution.# mysql -h172.xx.xx.12 -P3306 -utest -p -c -Amysql> /* to server cdbaro-rmoskdfp */ show databases;+---------------------+| Database |+---------------------+| INFORMATION_SCHEMA || Test1 || Test2 || __cdb_recycle_bin__ || haha || libra_system || test |+---------------------+7 rows in set (0.01 sec)
/*to ap*/ syntax.mysql> select /* to ap */ * from haha.t;+----+------+| id | haha |+----+------+| 1 | 1 || 2 | 2 |+----+------+2 rows in set (0.01 sec)
mysql> select /* to server cdbaro-rmoskdfp */ * from haha.t;+----+------+| id | haha |+----+------+| 1 | 1 || 2 | 2 |+----+------+2 rows in set (0.01 sec)
mysql> select /* to server cdbaro-rmoskdfp */ /*+ set_var(libra_enable_late_materialization=1) */ * from haha.t;+----+------+| id | haha |+----+------+| 1 | 1 || 2 | 2 |+----+------+2 rows in set (0.01 sec)
Was this page helpful?
You can also Contact sales or Submit a Ticket for help.
Help us improve! Rate your documentation experience in 5 mins.
Feedback