pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Marc G. Fournier <scrappy@postgresql.org>
To: pgsql-admin@postgresql.org
Subject: What is syslog:duration reporting ... ?
Date: Thu, 25 Aug 2005 15:28:21 -0300 (ADT)
Message-ID: <20050825152428.T1044@ganymede.hub.org> (raw)


'k, I've been wracking my brains over this today, and I'm either 
mis-understanding what is being reported *or* its reporting wrong ...

According to syslog:

LOG:  duration: 4107.987 ms  statement: UPDATE session SET hit_time=now() WHERE md5='8b8e7b7ff9b1b2ed5fc60218ced28d00';

But, if I do an EXPLAIN ANALYZE:

# explain analyze UPDATE session SET hit_time=now() WHERE md5='702c6cb20d5eb254c3feb2991e7e5e31';
                                                          QUERY PLAN
----------------------------------------------------------------------------------------------------------------------------
  Index Scan using session_md5_key on "session"  (cost=0.00..6.01 rows=1 width=93) (actual time=0.060..0.060 rows=0 loops=1)
    Index Cond: (md5 = '702c6cb20d5eb254c3feb2991e7e5e31'::bpchar)
  Total runtime: 0.171 ms
(3 rows)

And it doesn't matter what value I put for md5, I still get <1ms ...

I could see some variations, but almost 4000x slower  to *really* run the 
query vs an explain analyze?

This is with 7.4.2 ...

----
Marc G. Fournier           Hub.Org Networking Services (http://www.hub.org)
Email: scrappy@hub.org           Yahoo!: yscrappy              ICQ: 7615664



view thread (11+ messages)  latest in thread

Message-ID: <20050825152428.T1044@ganymede.hub.org>
Permalink:  ../20050825152428.T1044@ganymede.hub.org/
Also on:    postgresql.org/message-id/20050825152428.T1044@ganymede.hub.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: scrappy@postgresql.org
  Subject: Re: What is syslog:duration reporting ... ?
  In-Reply-To: <20050825152428.T1044@ganymede.hub.org>
  References: <20050825152428.T1044@ganymede.hub.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox