Skip site navigation (1) Skip section navigation (2)

What is syslog:duration reporting ... ?

From: "Marc G(dot) Fournier" <scrappy(at)postgresql(dot)org>
To: pgsql-admin(at)postgresql(dot)org
Subject: What is syslog:duration reporting ... ?
Date: 2005-08-25 18:28:21
Message-ID: 20050825152428.T1044@ganymede.hub.org (view raw or flat)
Thread:
Lists: pgsql-admin
'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(at)hub(dot)org           Yahoo!: yscrappy              ICQ: 7615664

Responses

pgsql-admin by date

Next:From: AldorDate: 2005-08-25 18:50:25
Subject: Re: What is syslog:duration reporting ... ?
Previous:From: Simon de HartogDate: 2005-08-25 18:27:18
Subject: Postgres using SSL connections

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group