Re: calculating time - Mailing list pgsql-general

From Bruno Wolff III
Subject Re: calculating time
Date
Msg-id 20030416165029.GB9649@wolff.to
Whole thread Raw
In response to Re: calculating time  (Alvaro Herrera <alvherre@dcc.uchile.cl>)
List pgsql-general
On Wed, Apr 16, 2003 at 08:26:27 -0400,
  Alvaro Herrera <alvherre@dcc.uchile.cl> wrote:
> On Wed, Apr 16, 2003 at 08:19:28AM -0400, Johnson, Shaunn wrote:
>
> > Nested Loop  (cost=0.00..5662254656.82 rows=138 width=199)
> >
> > The cost is supposed to be the amount of time it may take to
> > do a query, right?  So what, exactly, is this?  500 hours?
> > minutes?  CPU time?
>
> It's an arbitrary unit that can't be reliably converted into some
> real-world time.  You can try using EXPLAIN ANALYZE, which will execute
> the query and give you timed costs.  With that data you can also
> probably check that the estimates given by the planner are within some
> reasonable range.

But I wouldn't try it with the sample query since that won't finish in
a reasonable amount of time.

Just to get a rough idea of the scale factor, on my machine the estimated
cost is close to the execution time in milliseconds.


pgsql-general by date:

Previous
From: Jonathan Bartlett
Date:
Subject: Re: high availability
Next
From: Medi Montaseri
Date:
Subject: Re: Postgres Compare