Re: [GENERAL] Query timing

2007-03-05 Thread Robert Treat
On Monday 05 March 2007 02:38, Naz Gassiep wrote:
> That's not quite as fast as I would like to do it, that throws in a few
> more steps which slow down the development process. However if there is
> no way I will persevere with the method I have now.
> Thanks,
> - Naz.
>

There are several logging parameters in the postgresql.conf, including 
log_duration.  Logging to a file also has a bonus that you can feed it into a 
query analyzing program like pgfouine or pqa. 

-- 
Robert Treat
Build A Brighter LAMP :: Linux Apache {middleware} PostgreSQL

---(end of broadcast)---
TIP 3: Have you checked our extensive FAQ?

   http://www.postgresql.org/docs/faq


Re: [GENERAL] Query timing

2007-03-04 Thread Naz Gassiep
That's not quite as fast as I would like to do it, that throws in a few 
more steps which slow down the development process. However if there is 
no way I will persevere with the method I have now.

Thanks,
- Naz.

Jorge Godoy wrote:

Naz Gassiep <[EMAIL PROTECTED]> writes:

  

Using EXPLAIN ANALYZE I can get the execution time of a query. Is there a
command I can use to get the execution time without the planning information?
I just need to time lots of queries that have complex plans and it'd be easier
if I didn't have pages and pages of planning info between tries. The queries
themselves are one line each, but refer to views, which make the plans pretty
complex. Being able to see several times in one terminal window would be
easier.



Write the queries in a file, run them with psql -f and grep for the desired
lines only.

  


---(end of broadcast)---
TIP 2: Don't 'kill -9' the postmaster


Re: [GENERAL] Query timing

2007-03-04 Thread A. Kretschmer
am  Mon, dem 05.03.2007, um 15:28:29 +1100 mailte Naz Gassiep folgendes:
> Using EXPLAIN ANALYZE I can get the execution time of a query. Is there 
> a command I can use to get the execution time without the planning 

Within psql, the command-line-interface, you can use \timing to switch
on/off reporting the execution time.


Andreas
-- 
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net

---(end of broadcast)---
TIP 6: explain analyze is your friend


Re: [GENERAL] Query timing

2007-03-04 Thread Jorge Godoy
Naz Gassiep <[EMAIL PROTECTED]> writes:

> Using EXPLAIN ANALYZE I can get the execution time of a query. Is there a
> command I can use to get the execution time without the planning information?
> I just need to time lots of queries that have complex plans and it'd be easier
> if I didn't have pages and pages of planning info between tries. The queries
> themselves are one line each, but refer to views, which make the plans pretty
> complex. Being able to see several times in one terminal window would be
> easier.

Write the queries in a file, run them with psql -f and grep for the desired
lines only.

-- 
Jorge Godoy  <[EMAIL PROTECTED]>

---(end of broadcast)---
TIP 5: don't forget to increase your free space map settings