From 3bb7b9348140efb074b4ca382b43615c67de59aa Mon Sep 17 00:00:00 2001 From: echo77-nan <741548989@qq.com> Date: Fri, 26 Dec 2025 14:35:01 +0800 Subject: [PATCH] Update 06_sql_tuning.md unify expression. --- .../chapter_07_diagnosis_and_tuning/06_sql_tuning.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/user_manual/quick_starts/en-US/chapter_07_diagnosis_and_tuning/06_sql_tuning.md b/docs/user_manual/quick_starts/en-US/chapter_07_diagnosis_and_tuning/06_sql_tuning.md index db5fc833d..44731a866 100644 --- a/docs/user_manual/quick_starts/en-US/chapter_07_diagnosis_and_tuning/06_sql_tuning.md +++ b/docs/user_manual/quick_starts/en-US/chapter_07_diagnosis_and_tuning/06_sql_tuning.md @@ -67,7 +67,7 @@ Here are some examples: call dbms_stats.gather_schema_stats('TEST', degree=>128); ``` -> **Notice** +> **Note** > > The first parameter in the syntax of both the `GATHER_TABLE_STATS` and `GATHER_SCHEMA_STATS` procedures is `database_name` instead of `user_name`. The information in the documentation for some OceanBase Database versions may be incorrect. @@ -234,7 +234,7 @@ The output is as follows: +---------+------------+---------+---------+---------+------------+ ``` -> **Notice** +> **Note** > > The first column `TABLE_OWNER` of the `OCEANBASE.DBA_TAB_MODIFICATIONS` view indicates the database name rather than the user name. The information in the documentation for some OceanBase Database versions may be incorrect. @@ -544,13 +544,13 @@ You can also modify the parameterized SQL statement to prevent it from reusing a - Modify the parameterized SQL statement - > **Notice** + > **Note** > > This method is for your reference only. For example, you can add a space in the middle of the SQL statement to change `c2 = 1` to `c2 = 1`. For more information, see the `STATEMENT` field in the sample output below. - > **Notice** + > **Note** > > Add the space in the middle of the SQL statement. Do not add it in front of the first keyword or the semicolon (;). @@ -2022,7 +2022,7 @@ explain select * from t1 where c1 = 1 and c3 > 0 order by c2 limit 10; For the preceding SQL statement, a query range can be extracted from the equality condition `c1 = 1` for a fast index scan. Due to the equality condition on `c1`, the scan on the index `idx` returns a result set sorted by `c2`. After 10 rows are scanned, the execution of the plan is completed in advance. -> **Notice** +> **Note** > > The SQL statement has a `c3 > 0` predicate. If you create an index based on the `(c1, c3, c2)` order, the query range can be directly extracted from the index for filtering based on `c3 > 0`, but the result set is not sorted by `c2`. When the `c3 > 0` predicate is highly selective, the elimination of sorting for a streaming plan and reduced number of rows to scan basically do not bring any performance improvement. In this case, the use of `idx(c1, c2, c3)` only makes the plan unable to fully utilize the selectivity of `c3 > 0`. Therefore, the SQL tuning methods are not omnipotent and must be used in consideration of specific scenarios. @@ -2123,4 +2123,4 @@ create index idx on t1(c1, c2, c3); | range_key([t1.c1], [t1.c2], [t1.c3], [t1.pk]), range(0,MAX,MAX,MAX ; MAX,MAX,MAX,MAX), | | range_cond([t1.c1 > 0]) | +-----------------------------------------------------------------------------------------------+ - ``` \ No newline at end of file + ```