Creating a connection
In Yandex WebSQL, you can create a connection to:
- Managed database clusters in Yandex Cloud
- Public database via the internet
Connecting to a managed database cluster in Yandex Cloud
In Yandex WebSQL, you can connect to databases in the following clusters:
- Yandex Managed Service for PostgreSQL
- Yandex Managed Service for ClickHouse®
- Yandex Managed Service for MySQL®
- Yandex Managed Service for Valkey™
Before creating a connection, make sure that you have selected the required folder. If you have access to PostgreSQL, ClickHouse®, MySQL®, or Valkey™ clusters previously created in that folder, they will automatically appear in the Yandex Cloud connections subsection. You will only need to create a connection to the appropriate database in the cluster.
Connections to clusters created in Yandex MetaData Hub Connection Manager will also be displayed automatically, provided you have roles to manage these connections in Connection Manager.
To create a connection to a managed database cluster:
- Make sure WebSQL access is enabled in the cluster settings.
- Open Yandex WebSQL Connections
. - Under
Connections, click . - Name the connection.
- In the Database type field, select the DB you need: PostgreSQL, ClickHouse®, MySQL®, or Valkey™.
- In the Cluster field, select the managed database cluster you want to connect to.
- Specify the Username you will use to connect to cluster databases.
- Enter the user Password.
- List the Databases you want to connect to. You can only connect to the databases that exist in this cluster. The user you specified must have access to them configured.
- Click Create.
You can also create a connection to a cluster in Yandex MetaData Hub Connection Manager. This connection will automatically appear in Yandex WebSQL. But DB username, password, and name should be entered manually.
If the connection is successful, you will see the cluster structure in the connection tree. Connections to databases within a single managed database cluster are grouped into an expandable list under the name of that cluster.
Connecting to a public database
To connect to a public database via the internet:
-
Open Yandex WebSQL Connections
. -
In
Connections, click . -
In the bottom-left corner of the window that opens, click External connection.
-
Name the connection.
-
In the Database type field, select the database you need: PostgreSQL, ClickHouse®, MySQL®, or Valkey™.
-
Under Hosts, configure the hosts:
-
Specify the database host FQDN and port number for connecting to the database.
-
For ClickHouse®, also specify the Native Protocol port and shard name.
-
(Optional) Enable TLS.
If your company has a certification authority (CA), the certificate issued by the CA will be used by default. If the company has no CA, upload the server's TLS certificate.
-
-
Specify the Username you will use to connect to the database.
-
Enter the user Password.
-
List the Databases you want to connect to. You can only connect to existing databases. The user you specified must have access to them configured.
-
Click Create.
If the connection is successful, you will see the database structure in the connection tree.