[typo](docs)update array type doc #14057
This commit is contained in:
@ -38,15 +38,6 @@ T-type could be any of:
|
||||
BOOLEAN, TINYINT, SMALLINT, INT, BIGINT, LARGEINT, FLOAT, DOUBLE, DECIMAL, DATE,
|
||||
DATETIME, CHAR, VARCHAR, STRING
|
||||
```
|
||||
### notice
|
||||
|
||||
We should turn on the switch for the ARRAY types feature with the following command before use:
|
||||
|
||||
```
|
||||
$ mysql-client > admin set frontend config("enable_array_type"="true");
|
||||
```
|
||||
|
||||
In this way the config will be reset after the FE process restarts. For permanent setting, you can add config `enable_array_type=true` inside fe.conf.
|
||||
|
||||
### example
|
||||
|
||||
@ -71,9 +62,8 @@ Insert data example:
|
||||
|
||||
```
|
||||
mysql> INSERT INTO `array_test` VALUES (1, [1,2,3,4,5]);
|
||||
mysql> INSERT INTO `array_test` VALUES (2, array(6,7,8)), (3, array()), (4, null);
|
||||
mysql> INSERT INTO `array_test` VALUES (2, [6,7,8]), (3, []), (4, null);
|
||||
```
|
||||
Note: The above sql supports the array() function only in non-vectorized scenarios, but not in vectorized scenarios.
|
||||
|
||||
Select data example:
|
||||
|
||||
|
||||
@ -39,16 +39,6 @@ BOOLEAN, TINYINT, SMALLINT, INT, BIGINT, LARGEINT, FLOAT, DOUBLE, DECIMAL, DATE,
|
||||
DATETIME, CHAR, VARCHAR, STRING
|
||||
```
|
||||
|
||||
### notice
|
||||
|
||||
使用前可以通过如下命令打开Array开关:
|
||||
|
||||
```
|
||||
$ mysql-client > admin set frontend config("enable_array_type"="true");
|
||||
```
|
||||
|
||||
这种方式下Array开关会在Fe进程重启后重置,或者在fe.conf中添加`enable_array_type=true`配置项可永久生效。
|
||||
|
||||
### example
|
||||
|
||||
建表示例如下:
|
||||
@ -72,9 +62,8 @@ PROPERTIES (
|
||||
|
||||
```
|
||||
mysql> INSERT INTO `array_test` VALUES (1, [1,2,3,4,5]);
|
||||
mysql> INSERT INTO `array_test` VALUES (2, array(6,7,8)), (3, array()), (4, null);
|
||||
mysql> INSERT INTO `array_test` VALUES (2, [6,7,8]), (3, []), (4, null);
|
||||
```
|
||||
注意:以上sql仅在非向量化场景下,支持 array() 函数,向量化场景不支持。
|
||||
|
||||
查询数据示例:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user