Skip to content

Commit

Permalink
Add TiDB limitations (#2899)
Browse files Browse the repository at this point in the history
* Add TiDB limitations

* Update tidb-limitations.md

* address comments from lilian

* Update tidb-limitations.md

Co-authored-by: Keke Yi <40977455+yikeke@users.noreply.github.com>
Co-authored-by: Lilian Lee <lilin@pingcap.com>
Co-authored-by: ti-srebot <66930949+ti-srebot@users.noreply.github.com>
  • Loading branch information
4 people authored Jun 16, 2020
1 parent 48dd73b commit bf258db
Show file tree
Hide file tree
Showing 2 changed files with 75 additions and 0 deletions.
1 change: 1 addition & 0 deletions TOC.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
+ [Key Features](/key-features.md)
+ Compatibility
+ [MySQL Compatibility](/mysql-compatibility.md)
+ [TiDB Limitations](/tidb-limitations.md)
+ Quick Start
+ [Try Out TiDB](/quick-start-with-tidb.md)
+ [Learn TiDB SQL](/basic-sql-operations.md)
Expand Down
74 changes: 74 additions & 0 deletions tidb-limitations.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
---
title: TiDB Limitations
summary: Learn the usage limitations of TiDB.
category: introduction
---

# TiDB Limitations

This document describes the common usage limitations of TiDB, including the maximum identifier length and the maximum number of supported databases, tables, indexes, partitioned tables, and sequences.

## Limitations on identifier length

| Identifier type | Maximum length (number of characters allowed) |
|:---------|:--------------|
| Database | 64 |
| Table | 64 |
| Column | 64 |
| Index | 64 |
| View | 64 |
| Sequence | 64 |

## Limitations on the total number of databases, tables, views, and connections

| Identifier type | Maximum number |
|:----------|:----------|
| Databases | unlimited |
| Tables | unlimited |
| Views | unlimited |
| Connections| unlimited|

## Limitations on a single database

| Type | Upper limit |
|:----------|:----------|
| Tables | unlimited |

## Limitations on a single table

| Type | Upper limit |
|:----------|:----------|
| Columns | 512 |
| Indexes | 64 |
| Rows | unlimited |
| Size | unlimited |
| Partitions | 1024 |

## Limitation on a single row

| Type | Upper limit |
|:----------|:----------|
| Size | 6 MB |

## Limitation on a single column

| Type | Upper limit |
|:----------|:----------|
| Size | 6 MB |

## Limitations on string types

| Type | Upper limit |
|:----------|:----------|
| CHAR | 256 characters |
| BINARY | 256 characters |
| VARBINARY | 65535 characters |
| VARCHAR | 16383 characters |
| TEXT | 6 MB bytes |
| BLOB | 6 MB bytes |

## Limitations on SQL statements

| Type | Upper limit |
|:----------|:----------|
| The maximum number of SQL statements in a single transaction | When the optimistic transaction is used and the transaction retry is enabled, the default upper limit is 5000, which can be modified using [`stmt-count-limit`](/tidb-configuration-file.md#stmt-count-limit). |

0 comments on commit bf258db

Please sign in to comment.