You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by zh...@apache.org on 2022/07/18 06:13:12 UTC
[shardingsphere] branch master updated: add single table rql statement doc (#19310)
This is an automated email from the ASF dual-hosted git repository.
zhangliang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new 44cee99db0a add single table rql statement doc (#19310)
44cee99db0a is described below
commit 44cee99db0a62451f9c1070f96d239abf73b1672
Author: Jieker <ji...@163.com>
AuthorDate: Mon Jul 18 14:13:08 2022 +0800
add single table rql statement doc (#19310)
* feat(docs): add some single table rql statement
* fix(integration-test): Rollback configuration file.
---
.../syntax/rql/rule-query/single-table.cn.md | 24 +++++++++++++++++++++-
.../syntax/rql/rule-query/single-table.en.md | 24 +++++++++++++++++++++-
2 files changed, 46 insertions(+), 2 deletions(-)
diff --git a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.cn.md b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.cn.md
index fec2c6ae444..2db39631759 100644
--- a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.cn.md
+++ b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.cn.md
@@ -8,7 +8,9 @@ weight = 2
```sql
SHOW SINGLE TABLE (table | RULES) [FROM databaseName]
-SHOW SINGLE TABLES
+SHOW SINGLE TABLES
+
+COUNT SINGLE_TABLE RULE [FROM databaseName]
table:
TABLE tableName
@@ -30,6 +32,14 @@ table:
| table_name | 单表名称 |
| resource_name | 单表所在的数据源名称 |
+### Single Table Rule Count
+
+| 列 | 说明 |
+|-----------|---------------------|
+| rule_name | 规则名称 |
+| database | 单表所在的数据库名称 |
+| count | 规则个数 |
+
## 示例
*SHOW SINGLE TABLES RULES*
@@ -68,3 +78,15 @@ mysql> SHOW SINGLE TABLES;
+--------------+---------------+
2 rows in set (0.02 sec)
```
+
+*COUNT SINGLE_TABLE RULE*
+
+```sql
+mysql> COUNT SINGLE_TABLE RULE;
++--------------+----------+-------+
+| rule_name | database | count |
++--------------+----------+-------+
+| t_single_0 | ds | 2 |
++--------------+----------+-------+
+1 row in set (0.02 sec)
+```
diff --git a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.en.md b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.en.md
index 72a1d75859d..c508f59763b 100644
--- a/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.en.md
+++ b/docs/document/content/user-manual/shardingsphere-proxy/distsql/syntax/rql/rule-query/single-table.en.md
@@ -8,7 +8,9 @@ weight = 2
```sql
SHOW SINGLE TABLE (table | RULES) [FROM databaseName]
-SHOW SINGLE TABLES
+SHOW SINGLE TABLES
+
+COUNT SINGLE_TABLE RULE [FROM databaseName]
table:
TABLE tableName
@@ -30,6 +32,14 @@ table:
| table_name | Single table name |
| resource_name | The resource name where the single table is located |
+### Single Table Rule Count
+
+| 列 | 说明 |
+|-----------|-----------------------------------------------------|
+| rule_name | Single table rule name |
+| database | The database name where the single table is located |
+| count | The count of single table rules |
+
## Example
*SHOW SINGLE TABLES RULES*
@@ -68,3 +78,15 @@ mysql> SHOW SINGLE TABLES;
+--------------+---------------+
2 rows in set (0.02 sec)
```
+
+*COUNT SINGLE_TABLE RULE*
+
+```sql
+mysql> COUNT SINGLE_TABLE RULE;
++--------------+----------+-------+
+| rule_name | database | count |
++--------------+----------+-------+
+| t_single_0 | ds | 2 |
++--------------+----------+-------+
+1 row in set (0.02 sec)
+```