Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add description about limitation (#18774) #18829

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sql-statements/sql-statement-change-column.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ summary: TiDB 数据库中 CHANGE COLUMN 的使用概况。

从 v5.1.0 版本起,TiDB 开始支持 Reorg 数据的类型变更,包括但不限于:

- 从 varchar 转换为 bigint
- 从 varchar 转换为 bigint
- decimal 精度修改
- 从 varchar(10) 到 varchar(5) 的长度压缩

Expand Down Expand Up @@ -151,7 +151,7 @@ ERROR 8200 (HY000): Unsupported modify column: change from original type decimal
* 不支持主键列上 [Reorg-Data](/sql-statements/sql-statement-modify-column.md#reorg-data-change) 类型的变更。
* 不支持分区表上的列类型变更。
* 不支持生成列上的列类型变更。
* 不支持部分数据类型(例如,部分时间类型、Bit、Set、Enum、JSON 等)的变更,因为 TiDB `CAST` 函数与 MySQL 的行为存在兼容性问题。
* 不支持部分数据类型(例如,部分 TIME 类型、BIT、SET、ENUM、JSON 等)向某些类型的变更,因为 TiDB `CAST` 函数与 MySQL 的行为存在兼容性问题。

## 另请参阅

Expand Down
2 changes: 1 addition & 1 deletion sql-statements/sql-statement-modify-column.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ CREATE TABLE `t1` (
ERROR 8200 (HY000): Unsupported modify column: table is partition table
```

* 不支持部分数据类型(例如,部分时间类型、Bit、Set、Enum、JSON 等)的变更,因为 TiDB cast 函数与 MySQL 的行为有一些兼容性问题。例如:
* 不支持部分数据类型(例如,部分 TIME 类型、BIT、SET、ENUM、JSON 等)向某些类型的变更,因为 TiDB 的 `CAST` 函数与 MySQL 的行为有一些兼容性问题。例如:

```sql
CREATE TABLE t (a DECIMAL(13, 7));
Expand Down
4 changes: 4 additions & 0 deletions tidb-limitations.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ title: TiDB 使用限制

本文会将详细描述 TiDB 中常见的使用限制,包括:标识符长度,最大支持的数据库、表、索引、分区表、序列等的个数。

> **注意:**
>
> TiDB 高度兼容 MySQL 协议,也兼容了很多 MySQL 本身的限制,比如单个索引最多可包含 16 列。详细请参考[与 MySQL 兼容性对比](/mysql-compatibility.md) 和 MySQL 官方文档。

## 标识符长度限制

| 标识符类型 | 最大长度(字符)|
Expand Down
Loading