Re: Confused by 'timing' results

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: <pgsql-admin(at)postgresql(dot)org>,"A J" <s5aly(at)yahoo(dot)com>
Subject: Re: Confused by 'timing' results
Date: 2010-08-31 18:14:27
Message-ID: 4C7D00330200002500034ED2@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

A J <s5aly(at)yahoo(dot)com> wrote:

> time echo '\timing \\select * from table1 where id = 123;' | psql

> In the above query. the 'timing' will time the database time and
> the 'time' command at the very start will time the complete time
> for the query including network time.

No, the 'timing' will say how long it took to send the query from
psql to the server and get the complete response back from the
server. The 'time' command will also include the time to start
psql, establish the connection to the database, read from the pipe,
and close the connection to the database.

-Kevin

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message A J 2010-08-31 19:01:36 Re: Confused by 'timing' results
Previous Message A J 2010-08-31 17:42:16 Confused by 'timing' results