Re: prepared statements don't log arguments?

From: Simon Riggs
Subject: Re: prepared statements don't log arguments?
Date: ,
Msg-id: 1112942943.16721.1178.camel@localhost.localdomain
(view: Whole thread, Raw)
In response to: Re: prepared statements don't log arguments?  (Palle Girgensohn)
Responses: Re: prepared statements don't log arguments?  (Oliver Jowett)
List: pgsql-hackers

Tree view

prepared statements don't log arguments?  (Palle Girgensohn, )
 Re: prepared statements don't log arguments?  (Greg Stark, )
  Re: prepared statements don't log arguments?  (Christopher Kings-Lynne, )
   Re: prepared statements don't log arguments?  (Neil Conway, )
    Re: prepared statements don't log arguments?  (Abhijit Menon-Sen, )
    Re: prepared statements don't log arguments?  (Alvaro Herrera, )
    Re: prepared statements don't log arguments?  (Oliver Jowett, )
     Re: prepared statements don't log arguments?  (Neil Conway, )
     Re: prepared statements don't log arguments?  (Tom Lane, )
  Re: prepared statements don't log arguments?  (Oliver Jowett, )
   Re: prepared statements don't log arguments?  (Palle Girgensohn, )
 Re: prepared statements don't log arguments?  (Simon Riggs, )
  Re: prepared statements don't log arguments?  (Palle Girgensohn, )
   Re: prepared statements don't log arguments?  (Simon Riggs, )
    Re: prepared statements don't log arguments?  (Oliver Jowett, )
     Re: prepared statements don't log arguments?  (Tom Lane, )
      Re: prepared statements don't log arguments?  (Simon Riggs, )
       Re: prepared statements don't log arguments?  (Oliver Jowett, )
        Re: prepared statements don't log arguments?  (Simon Riggs, )
         Re: prepared statements don't log arguments?  (Oliver Jowett, )

On Fri, 2005-04-08 at 00:51 +0200, Palle Girgensohn wrote:
> --On torsdag, april 07, 2005 23.31.52 +0100 Simon Riggs 
> <> wrote:
> 
> > On Wed, 2005-04-06 at 15:01 +0200, Palle Girgensohn wrote:
> >> I really need to know the *real* arguments...
> >
> > Why do you need to log the arguments as well?
> 
> Debugging purposes. If I fealize there are queries hogging the server, I'd 
> like to get them from a log so I can tune the system, maybe add an index or 
> find the qurey in the src code an rephrase it. It is *very* helpful to a 
> proper set of arguments for a slow query, since another set of arguments 
> will probably give a very speedy result. I need to find the hogs, basically.

OK, thats what I hoped you'd say. With a prepared query all of the
statements execute the same plan, so you don't need to know the exact
parameters. Before v3 the whole query was logged because the statements
were not prepared and each query might have been different. That is no
longer the case.

ISTM that for analysis purposes it is helpful to know that a particular
query is being repeated. Also, if you log the actual parameters, the log
gets unusefully large very quickly.

Anyway, I have a patch that I will be able to submit shortly in this
area. No doubt it will require further discussion.

Best Regards, Simon Riggs




pgsql-hackers by date:

From: Bernd Helmle
Date:
Subject: Re: Call for objections: merge Resdom with TargetEntry
From: "Sergey E. Koposov"
Date:
Subject: Tab-completion feature ?