Skip to content

Commit

Permalink
reference/configuration: add tidb_row_format_version (pingcap#2605)
Browse files Browse the repository at this point in the history
  • Loading branch information
lysu authored and sre-bot committed Apr 15, 2020
1 parent 23beea4 commit 3f6f014
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions reference/configuration/tidb-server/tidb-specific-variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -430,6 +430,18 @@ set @@global.tidb_distsql_scan_concurrency = 10;
- `CREATE TABLE``CREATE TABLE t (c int) SHARD_ROW_ID_BITS = 4;`
- `ALTER TABLE``ALTER TABLE t SHARD_ROW_ID_BITS = 4;`

### tidb_row_format_version

作用域:GLOBAL

默认值:2

控制新保存数据的表数据格式版本。TiDB v4.0 中默认使用版本号为 2 的[新表数据格式](https://github.com/pingcap/tidb/blob/master/docs/design/2018-07-19-row-format.md)保存新数据。

但如果从 4.0.0 之前的版本升级到 4.0.0,不会改变表数据格式版本,TiDB 会继续使用版本为 1 的旧格式写入表中,即**只有新创建的集群才会默认使用新表数据格式**

需要注意的是修改该变量不会对已保存的老数据产生影响,只会对修改变量后的新写入数据使用对应版本格式保存。

### tidb_slow_log_threshold

作用域:SESSION
Expand Down

0 comments on commit 3f6f014

Please sign in to comment.