Search Postgresql Archives

Re: Understanding EXPLAIN ANALYZE output

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

 



"Ed L." <pgsql@xxxxxxxxxxxxx> writes:
> If the second number of the "actual time" part means time 
> elapsed in this node and its children until the last row was 
> returned, why does it say "actual time=4.63..4.63" instead of 
> "actual time=4.63..4767.62"?

The reason we do that is to make the "actual" numbers comparable to the
way that the estimated costs are presented.  The estimated costs are for
a single execution of the node, but the inner side of a nestloop join is
re-executed for each row coming from the outer side.  In this case, the
outer side produced 1014 rows so we ran 1014 separate executions of the
inner indexscan.  If we just reported 4767.62 as the total time, it
would look like the estimated indexscan cost of 10.28 was completely out
of whack, which it isn't.  So instead, we report a per-execution cost
and a "loops" number that you have to multiply by if you are thinking
about total time spent.

			regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
    (send "unregister YourEmailAddressHere" to majordomo@xxxxxxxxxxxxxx)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux