Yandex Cloud
Search
Discuss with expertTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
    • Cloud Interconnect
    • Cloud Backup
    • Cloud Registry
    • Yandex AI Studio
    • Compute Cloud
    • Object Storage
    • Managed Service for Kubernetes®
    • Yandex BareMetal
    • Smart Web Security
    • Security Deck
    • Managed Service for PostgreSQL
    • Managed Service for ClickHouse®
    • Monium
    • Cloud CDN
    • Network Load Balancer
    • Virtual Private Cloud
    • Cloud DNS
    • Application Load Balancer
    • Yandex Cloud Video
    • Stackland
    • Yandex Cloud Router
    • Yandex Managed Service for Trino
    • Managed Service for MySQL®
    • Managed Service for Valkey™
    • Managed Service for Apache Spark™
    • Yandex StoreDoc
    • Managed Service for OpenSearch
    • Managed Service for Apache Kafka®
    • Data Transfer
    • Yandex MPP Analytics Engine for PostgreSQL
    • Yandex Managed Service for Apache Airflow®
    • Data Processing
    • Yandex MetaData Hub
    • Managed Service for YDB
    • Managed Service for Sharded PostgreSQL
    • Managed Service for YTsaurus
    • Yandex WebSQL
    • DataLens
    • Yandex Search API
    • SpeechSense
    • SpeechKit
    • DataSphere
    • Vision OCR
    • Translate
    • Yandex Identity Hub
    • Key Management Service
    • Certificate Manager
    • Yandex Lockbox
    • Audit Trails
    • SmartCaptcha
    • Cloud Desktop
    • SourceCraft Code Assistant
    • Container Registry
    • Managed Service for GitLab
    • Managed Service for Prometheus®
    • Cloud Functions
    • API Gateway
    • Yandex Cloud Postbox
    • Message Queue
    • Serverless Integrations
    • IoT Core
    • Data Streams
    • Serverless Containers
    • Cloud Notification Service
    • Yandex Query
    • Identity and Access Management
    • Yandex Cloud Console
    • Resource Manager
    • Yandex Cloud Billing
    • Yandex Cloud Quota Manager
    • Cloud Apps
  • System Status
  • Marketplace
    • Featured
    • Infrastructure & Network
    • Data Platform
    • AI for business
    • Security
    • DevOps tools
    • Serverless
    • Monitoring & Resources
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
    • Price calculator
    • Pricing plans
  • Customer Stories
  • Documentation
  • Blog
© 2026 Direct Cursus Technology L.L.C.
Yandex DataLens
  • DataLens neuroanalyst
    • Overview
    • Versioning
    • Caching
    • Combining data
    • Adding connection info
      • Creating a ClickHouse® connection
      • Creating a PostgreSQL connection
      • Creating a MySQL® connection
      • Creating a YDB connection
      • Creating a Greenplum® connection
      • Creating a SQL Server connection
      • Creating an Oracle Database connection
      • Creating a StarRocks connection
      • Creating a Prometheus connection
      • Creating a Snowflake connection
      • Creating a Trino connection
  • Gallery in DataLens
  • Audit Trails events
  1. Connections
  2. Databases
  3. Creating a YDB connection

Creating a connection to YDB from Yandex DataLens

Written by
Yandex Cloud
Improved by
Max Z.
Updated at July 17, 2026
View in Markdown

Note

To create a connection, you will need a service account with the ydb.viewer or viewer role.

To write subqueries in datasets and queries in QL charts, use the YQL syntax.

To create a YDB connection:

  1. Open the connection creation page.

  2. Under Files and services, select the YDB connection.

  3. Configure the connection as follows:

    • Cloud and folder: Select the folder where your service account will be located.
    • Service account: Select an existing service account or create a new one.
    • Database: Select the database to connect or create a new one.

    Warning

    Capital letters are not allowed in YDB database column names.

    • Cache TTL in seconds: Specify cache TTL or leave the default value. The recommended value is 300 seconds (5 minutes).
    • Raw SQL level: Enables you to use an ad-hoc SQL query to generate a dataset. This option is disabled by default. When enabling it, you will need to select the raw SQL level:

      • Subqueries only: Describe dataset sources using SQL queries.
      • Subqueries and parameters: Describe dataset sources using SQL queries and use source parameterization.
      • SQL to read: Describe dataset sources using SQL queries, use source parameterization, and create QL charts.
  4. Optionally, test the connection by clicking Check connection.

  5. Click Create connection.

  6. Select a workbook to save your connection to or create a new one. If using legacy folder navigation, select a folder to save the connection to. Click Create.

  7. Enter a name for the connection and click Create.

RESOURCE_EXHAUSTED error

If the Managed Service for YDB quotas and limits are exceeded, you may get the RESOURCE_EXHAUSTED error message. To avoid the error, follow these recommendations:

  • Reduce the query rate. To achieve this, you can use filters or specify only the required chart fields to limit the amount of data you get.
  • Follow the recommendations for database query optimization.
  • Use the DataLens chart inspector to assess the data amount and upload time.
  • Check the Managed Service for YDB monitoring charts for exceeded quotas and limits. If you need to, you may slightly increase the throughput capacity (request units, RUs) limit under Limits.

Note

Increasing the throughput limit in the serverless database settings may result in high usage costs. Since serverless database resources are indefinitely large, the maximum consumption of RUs over a period of time can also reach any value, leading to excessive charges. When changing it, increase the value by only a very small amount, e.g., by 10 RUs per second.

Was the article helpful?

Previous
Creating a MySQL® connection
Next
Connection
© 2026 Direct Cursus Technology L.L.C.