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

sequence: remove the order keyword of sequence (#7417) #7558

Merged
Merged
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: 1 addition & 3 deletions sql-statements/sql-statement-create-sequence.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ CREATE [TEMPORARY] SEQUENCE [IF NOT EXISTS] sequence_name
[ START [ WITH | = ] start ]
[ CACHE [=] cache | NOCACHE | NO CACHE]
[ CYCLE | NOCYCLE | NO CYCLE]
[ ORDER | NOORDER | NO ORDER]
[table_options]
```

Expand All @@ -59,10 +58,9 @@ CREATE [TEMPORARY] SEQUENCE [IF NOT EXISTS] sequence_name
| `INCREMENT` | `1` | 指定序列的步长。其正负值可以控制序列的增长方向。|
| `MINVALUE` | `1` 或 `-9223372036854775807` | 指定序列的最小值。当 `INCREMENT` > `0` 时,默认值为 `1`;当 `INCREMENT` < `0` 时,默认值为 `-9223372036854775807`。|
| `MAXVALUE` | `9223372036854775806` 或 `-1` | 指定序列的最大值。当 `INCREMENT` > `0` 时,默认值为 `9223372036854775806`;当 `INCREMENT` < `0` 时,默认值为 `-1`。|
| `START` | `MINVALUE` 或 `MAXVALUE` | 指定序列的初始值。当 `INCREMENT` > `0` 时,默认值为 `MINVALUE`; 当 `INCREMENT` < `0` 时,默认值为 `MAXVALUE`。|
| `START` | `MINVALUE` 或 `MAXVALUE` | 指定序列的初始值。当 `INCREMENT` > `0` 时,默认值为 `MINVALUE`; 当 `INCREMENT` < `0` 时,默认值为 `MAXVALUE`。 |
| `CACHE` | `1000` | 指定每个 TiDB 本地缓存序列的大小。|
| `CYCLE` | `NO CYCLE` | 指定序列用完之后是否要循环使用。在 `CYCLE` 的情况下,当 `INCREMENT` > `0` 时,序列用完后的后续起始值为 `MINVALUE`;当 `INCREMENT` < `0` 时,序列用完后的后续起始值为 `MAXVALUE`。|
| `ORDER` | `NO ORDER` | TiDB 暂时不支持 `ORDER` 选项,仅在语法上做兼容。|

## `SEQUENCE` 函数

Expand Down