Skip to content

Commit

Permalink
Add JSON_SCHEMA_VALID (#17602)
Browse files Browse the repository at this point in the history
  • Loading branch information
hfxsd authored Jun 28, 2024
1 parent ca58646 commit c54dbcc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
7 changes: 6 additions & 1 deletion functions-and-operators/json-functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,19 @@ TiDB 支持 MySQL 8.0 中提供的大部分 [JSON 函数](https://dev.mysql.com/
| [JSON_ARRAYAGG(key)](https://dev.mysql.com/doc/refman/8.0/en/aggregate-functions.html#function_json-arrayagg) | 提供指定列 key 的聚合 |
| [JSON_OBJECTAGG(key, value)](https://dev.mysql.com/doc/refman/8.0/en/aggregate-functions.html#function_json-objectagg) | 提供给定两列键值对的聚合 |

## 验证函数

| 函数 | 功能描述 |
| --------------------------------- | ----------- |
| [JSON_SCHEMA_VALID(schema,json_doc)](https://dev.mysql.com/doc/refman/8.0/en/json-validation-functions.html#function_json-schema-valid) | 根据 schema 验证 JSON 文档,确保数据的完整性和一致性 |

## 另请参阅

* [JSON Function Reference](https://dev.mysql.com/doc/refman/8.0/en/json-function-reference.html)
* [JSON Data Type](/data-type-json.md)

## 不支持的函数

- `JSON_SCHEMA_VALID()`
- `JSON_SCHEMA_VALIDATION_REPORT()`
- `JSON_TABLE()`
- `JSON_VALUE()`
Expand Down
1 change: 1 addition & 0 deletions sql-statements/sql-statement-show-builtins.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,7 @@ SHOW BUILTINS;
| json_quote |
| json_remove |
| json_replace |
| json_schema_valid |
| json_search |
| json_set |
| json_storage_size |
Expand Down

0 comments on commit c54dbcc

Please sign in to comment.