> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bijection.com/llms.txt
> Use this file to discover all available pages before exploring further.

# TiDB table observations

> Observe one TiDB relation over the native MySQL receiver.

Follow the [MySQL mount and credential guide](https://docs.bijection.com/integrations/native-mysql.md).
Bind `mysqlRelation(endpoint, credential, data)` to a TLS-enabled
TiDB SQL endpoint with MySQL password login. Add `"dialect": "tidb"`
and, if needed, `ca` PEM text to the sealed JSON. Use TiDB 6.5 or later
with metadata locking enabled, a SELECT-only role and the same
[`data` label](https://docs.bijection.com/integrations/native-connectors#installer-bound-labels)
for the receiver and the mount.

TiDB speaks MySQL classic protocol and supports server-side prepared
statements. It uses snapshot isolation for MySQL's REPEATABLE READ
setting. TiDB accepts read-only transaction syntax without enforcing it,
so restrict the database principal to SELECT. This connector uses the
logical `TIDB_TABLE_ID` and verifies the metadata-lock setting. It does not
use MySQL's physical server UUID as a TiDB source identity. Use
`incarnation` to distinguish a replacement that could reuse logical IDs.

Use the full one-to-eight-column signed bigint or text primary key and
up to sixteen projection columns. Bijection commits up to 32 rows,
24 KiB per JSON row and 48 KiB of encoded data per page with the last
key tuple. Each page has its own snapshot. Missing keys stay published.
This mode covers observations. TiCDC has a separate feed protocol.

[TiDB isolation](https://docs.pingcap.com/tidb/stable/transaction-isolation-levels/) ·
[Metadata locks](https://docs.pingcap.com/tidb/stable/metadata-lock/)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.