This is an automated email from the ASF dual-hosted git repository.

tomshawn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cloudberry-site.git


The following commit(s) were added to refs/heads/main by this push:
     new 3f92d9dab doc: add a missing step to using index scan on ao tables 
(#268)
3f92d9dab is described below

commit 3f92d9dab5d339793a1968afe8e948fab55d6f8b
Author: TomShawn <[email protected]>
AuthorDate: Mon May 19 14:20:13 2025 +0800

    doc: add a missing step to using index scan on ao tables (#268)
---
 docs/performance/use-index-scan-on-ao-tables.md                        | 3 +++
 .../current/performance/use-index-scan-on-ao-tables.md                 | 3 +++
 .../version-1.x/performance/use-index-scan-on-ao-tables.md             | 3 +++
 .../version-2.x/performance/use-index-scan-on-ao-tables.md             | 3 +++
 versioned_docs/version-1.x/performance/use-index-scan-on-ao-tables.md  | 3 +++
 versioned_docs/version-2.x/performance/use-index-scan-on-ao-tables.md  | 3 +++
 6 files changed, 18 insertions(+)

diff --git a/docs/performance/use-index-scan-on-ao-tables.md 
b/docs/performance/use-index-scan-on-ao-tables.md
index 5927d1051..e0a4bcb7e 100644
--- a/docs/performance/use-index-scan-on-ao-tables.md
+++ b/docs/performance/use-index-scan-on-ao-tables.md
@@ -48,6 +48,9 @@ SET optimizer TO off; -- To enable AO IndexScan, first 
disable the GPORCA optimi
 CREATE TABLE tbl (id int, val int) WITH (orientation='column', 
appendonly=true);
 INSERT INTO tbl SELECT i, i FROM generate_series(1, 100000000) s(i);
 
+-- Creates an index on the val column.
+CREATE INDEX idx_val ON tbl(val);
+
 -- Directly runs a query.
 EXPLAIN ANALYZE SELECT * FROM tbl WHERE val > 100 ORDER BY val LIMIT 10;
 
diff --git 
a/i18n/zh/docusaurus-plugin-content-docs/current/performance/use-index-scan-on-ao-tables.md
 
b/i18n/zh/docusaurus-plugin-content-docs/current/performance/use-index-scan-on-ao-tables.md
index 179671c30..9037c25bd 100644
--- 
a/i18n/zh/docusaurus-plugin-content-docs/current/performance/use-index-scan-on-ao-tables.md
+++ 
b/i18n/zh/docusaurus-plugin-content-docs/current/performance/use-index-scan-on-ao-tables.md
@@ -50,6 +50,9 @@ SET optimizer TO off; -- 要启用 AO IndexScan,需要先关闭 ORCA 优化器
 CREATE TABLE tbl (id int, val int) WITH (orientation='column', 
appendonly=true);
 INSERT INTO tbl SELECT i, i FROM generate_series(1, 100000000) s(i);
 
+-- 创建 val 列的索引
+CREATE INDEX idx_val ON tbl(val);
+
 -- 直接进行查询
 EXPLAIN ANALYZE SELECT * FROM tbl WHERE val > 100 ORDER BY val LIMIT 10;
 
diff --git 
a/i18n/zh/docusaurus-plugin-content-docs/version-1.x/performance/use-index-scan-on-ao-tables.md
 
b/i18n/zh/docusaurus-plugin-content-docs/version-1.x/performance/use-index-scan-on-ao-tables.md
index 179671c30..9037c25bd 100644
--- 
a/i18n/zh/docusaurus-plugin-content-docs/version-1.x/performance/use-index-scan-on-ao-tables.md
+++ 
b/i18n/zh/docusaurus-plugin-content-docs/version-1.x/performance/use-index-scan-on-ao-tables.md
@@ -50,6 +50,9 @@ SET optimizer TO off; -- 要启用 AO IndexScan,需要先关闭 ORCA 优化器
 CREATE TABLE tbl (id int, val int) WITH (orientation='column', 
appendonly=true);
 INSERT INTO tbl SELECT i, i FROM generate_series(1, 100000000) s(i);
 
+-- 创建 val 列的索引
+CREATE INDEX idx_val ON tbl(val);
+
 -- 直接进行查询
 EXPLAIN ANALYZE SELECT * FROM tbl WHERE val > 100 ORDER BY val LIMIT 10;
 
diff --git 
a/i18n/zh/docusaurus-plugin-content-docs/version-2.x/performance/use-index-scan-on-ao-tables.md
 
b/i18n/zh/docusaurus-plugin-content-docs/version-2.x/performance/use-index-scan-on-ao-tables.md
index 179671c30..9037c25bd 100644
--- 
a/i18n/zh/docusaurus-plugin-content-docs/version-2.x/performance/use-index-scan-on-ao-tables.md
+++ 
b/i18n/zh/docusaurus-plugin-content-docs/version-2.x/performance/use-index-scan-on-ao-tables.md
@@ -50,6 +50,9 @@ SET optimizer TO off; -- 要启用 AO IndexScan,需要先关闭 ORCA 优化器
 CREATE TABLE tbl (id int, val int) WITH (orientation='column', 
appendonly=true);
 INSERT INTO tbl SELECT i, i FROM generate_series(1, 100000000) s(i);
 
+-- 创建 val 列的索引
+CREATE INDEX idx_val ON tbl(val);
+
 -- 直接进行查询
 EXPLAIN ANALYZE SELECT * FROM tbl WHERE val > 100 ORDER BY val LIMIT 10;
 
diff --git 
a/versioned_docs/version-1.x/performance/use-index-scan-on-ao-tables.md 
b/versioned_docs/version-1.x/performance/use-index-scan-on-ao-tables.md
index 5927d1051..e0a4bcb7e 100644
--- a/versioned_docs/version-1.x/performance/use-index-scan-on-ao-tables.md
+++ b/versioned_docs/version-1.x/performance/use-index-scan-on-ao-tables.md
@@ -48,6 +48,9 @@ SET optimizer TO off; -- To enable AO IndexScan, first 
disable the GPORCA optimi
 CREATE TABLE tbl (id int, val int) WITH (orientation='column', 
appendonly=true);
 INSERT INTO tbl SELECT i, i FROM generate_series(1, 100000000) s(i);
 
+-- Creates an index on the val column.
+CREATE INDEX idx_val ON tbl(val);
+
 -- Directly runs a query.
 EXPLAIN ANALYZE SELECT * FROM tbl WHERE val > 100 ORDER BY val LIMIT 10;
 
diff --git 
a/versioned_docs/version-2.x/performance/use-index-scan-on-ao-tables.md 
b/versioned_docs/version-2.x/performance/use-index-scan-on-ao-tables.md
index 5927d1051..e0a4bcb7e 100644
--- a/versioned_docs/version-2.x/performance/use-index-scan-on-ao-tables.md
+++ b/versioned_docs/version-2.x/performance/use-index-scan-on-ao-tables.md
@@ -48,6 +48,9 @@ SET optimizer TO off; -- To enable AO IndexScan, first 
disable the GPORCA optimi
 CREATE TABLE tbl (id int, val int) WITH (orientation='column', 
appendonly=true);
 INSERT INTO tbl SELECT i, i FROM generate_series(1, 100000000) s(i);
 
+-- Creates an index on the val column.
+CREATE INDEX idx_val ON tbl(val);
+
 -- Directly runs a query.
 EXPLAIN ANALYZE SELECT * FROM tbl WHERE val > 100 ORDER BY val LIMIT 10;
 


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to