Re: Difference between explain analyze and real execution time

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> EXPLAIN ANALYZE doesn't account for all of the runtime involved.  In this
case, I'd bet that session startup/shutdown is a big part of the difference.
> 
>			regards, tom lane

Does session startup/shutdown depend on tables used in query? Some simpler
query:

time psql  -c 'explain analyze SELECT te.idt FROM t_positions AS te    WHERE
te.idtr IN (347186)'

                                                             QUERY PLAN
----------------------------------------------------------------------------
---------------------------------------------------------
 Index Scan using tg_transelem_index1 on tg_transelem te  (cost=0.00..8.43
rows=3 width=4) (actual time=0.130..0.134 rows=3 loops=1)
   Index Cond: (tr_idtrans = 347186)
 Total runtime: 0.211 ms


real    0m0.017s
user    0m0.002s
sys     0m0.004s



-------------------------------------------
Artur Zajac




-- 
Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance


[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux