Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Gpdb
提交
fc08814e
G
Gpdb
项目概览
Greenplum
/
Gpdb
通知
7
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
Gpdb
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
fc08814e
编写于
4月 23, 1999
作者:
B
Bruce Momjian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Rename explain's "size" to "rows".
上级
35b16865
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
14 addition
and
11 deletion
+14
-11
doc/src/sgml/ref/explain.sgml
doc/src/sgml/ref/explain.sgml
+3
-1
src/backend/commands/explain.c
src/backend/commands/explain.c
+2
-2
src/man/explain.l
src/man/explain.l
+9
-8
未找到文件。
doc/src/sgml/ref/explain.sgml
浏览文件 @
fc08814e
...
...
@@ -102,6 +102,8 @@ Description
<PARA>
This command outputs details about the supplied query.
The default output is the computed query cost.
The cost value is only meaningful to the optimizer in comparing
various query plans.
VERBOSE displays the full query plan and cost to your screen,
and pretty-prints the plan to the postmaster log file.
</para>
...
...
@@ -135,7 +137,7 @@ To show a query plan for a simple query:
postgres=> explain select * from foo;
NOTICE: QUERY PLAN:
Seq Scan on foo (cost=0.00
size
=0 width=4)
Seq Scan on foo (cost=0.00
rows
=0 width=4)
EXPLAIN
</ProgramListing>
...
...
src/backend/commands/explain.c
浏览文件 @
fc08814e
...
...
@@ -4,7 +4,7 @@
*
* Copyright (c) 1994-5, Regents of the University of California
*
* $Id: explain.c,v 1.3
3 1999/03/23 16:50:46
momjian Exp $
* $Id: explain.c,v 1.3
4 1999/04/23 21:23:48
momjian Exp $
*
*/
#include <stdio.h>
...
...
@@ -234,7 +234,7 @@ explain_outNode(StringInfo str, Plan *plan, int indent, ExplainState *es)
}
if
(
es
->
printCost
)
{
appendStringInfo
(
str
,
" (cost=%.2f
size
=%d width=%d)"
,
appendStringInfo
(
str
,
" (cost=%.2f
rows
=%d width=%d)"
,
plan
->
cost
,
plan
->
plan_size
,
plan
->
plan_width
);
}
appendStringInfo
(
str
,
"
\n
"
);
...
...
src/man/explain.l
浏览文件 @
fc08814e
.\" This is -*-nroff-*-
.\" XXX standard disclaimer belongs here....
.\" $Header: /cvsroot/pgsql/src/man/Attic/explain.l,v 1.1
0 1998/08/04 15:00:28
momjian Exp $
.\" $Header: /cvsroot/pgsql/src/man/Attic/explain.l,v 1.1
1 1999/04/23 21:23:49
momjian Exp $
.TH EXPLAIN SQL 06/12/97 PostgreSQL PostgreSQL
.SH NAME
explain - explains statement execution details
...
...
@@ -10,21 +10,22 @@ explain - explains statement execution details
.fi
.SH DESCRIPTION
This command outputs details about the supplied query. The default
output is the computed query cost. \f2verbose\f1 displays the full query
plan and cost to your screen, and pretty-prints the plan to the postmaster
log file.
output is the computed query cost. The cost value is only meaningful to
the optimizer in comparing various query plans. \f2verbose\f1 displays
the full query plan and cost to your screen, and pretty-prints the plan
to the postmaster log file.
.SH EXAMPLES
In the examples, the table has a single column of float4.
\fBcost\fR is the cost of scanning a base/join relation,
\fB
size\fR is the expected number of tuple
s from a scan,
\fB
rows\fR is the expected number of row
s from a scan,
\fBwidth\fR is the length of a tuple.
.nf
tgl=> explain select a from test\g
NOTICE:QUERY PLAN:
Seq Scan on test (cost=0.00
size
=0 width=4)
Seq Scan on test (cost=0.00
rows
=0 width=4)
EXPLAIN
tgl=> explain verbose select sum(a) from test;
...
...
@@ -41,8 +42,8 @@ NOTICE:QUERY PLAN:
:expr {VAR :varno 1 :varattno 1 :vartype 700 :varnoold 1 :varoattno 1}})
:qpqual <> :lefttree <> :righttree <> :scanrelid 1} :righttree <> :numagg 1 }
Aggregate (cost=0.00
size
=0 width=0)
-> Seq Scan on test (cost=0.00
size
=0 width=4)
Aggregate (cost=0.00
rows
=0 width=0)
-> Seq Scan on test (cost=0.00
rows
=0 width=4)
.fi
The Postgres optimizer has chosen to use a sequential scan to retrieve rows from
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录