From: Raghavendra [mailto:raghavendra.rao@enterprisedb.com]
Sent: 25 March 2015 12:04 PM
To: Khangelani Gama
Cc: pgsql-admin
Subject: Re: [ADMIN] Postgres 9 : - How to interpret the EXPLAIN query results
Hi
Please help, how can I interpret the following results of my EXPLAIN query ?, I can see that the query will through 18586018 rows, but what’s the meaning of cost and width?
GroupAggregate (cost=762381141.96..768375132.77 rows=18586018 width=32)
NodeType (cost=startup-cost..total-cost rows=plan rows width=bytes per-row)
Documentation has briefed well on the explain output. Here's example.
Thanks to all, but if this total cost is the total time it will take to retrieve the output then is it in minutes or milliseconds? If it’s in milliseconds does it mean that it take about 213 hrs for a total of 768375132.77
postgres=# explain select * from foo;
-----------------------------------------------------------
Seq Scan on foo (cost=0.00..5770.01 rows=400001 width=4)
postgres=# EXPLAIN (FORMAT JSON) SELECT * FROM foo;
--------------------------------
"Node Type": "Seq Scan",+
"Relation Name": "foo", +
CONFIDENTIALITY NOTICE
The contents of and attachments to this e-mail are intended for the addressee only, and may contain the confidential
information of Argility (Proprietary) Limited and/or its subsidiaries. Any review, use or dissemination thereof by anyone
other than the intended addressee is prohibited.If you are not the intended addressee please notify the writer immediately
and destroy the e-mail. Argility (Proprietary) Limited and its subsidiaries distance themselves from and accept no liability
for unauthorised use of their e-mail facilities or e-mails sent other than strictly for business purposes.
CONFIDENTIALITY NOTICE
The contents of and attachments to this e-mail are intended for the addressee only, and may contain the confidential
information of Argility (Proprietary) Limited and/or its subsidiaries. Any review, use or dissemination thereof by anyone
other than the intended addressee is prohibited.If you are not the intended addressee please notify the writer immediately
and destroy the e-mail. Argility (Proprietary) Limited and its subsidiaries distance themselves from and accept no liability
for unauthorised use of their e-mail facilities or e-mails sent other than strictly for business purposes.