From: Rigmor Ukuhe <rigmor.ukuhe@finestmedia.ee>
To: pgsql-admin@postgresql.org
Subject: Re: Logging just SQL commands in an SQL script format
Date: Thu, 25 Jan 2007 15:21:25 +0200
Message-ID: <45B8AED5.3090905@finestmedia.ee> (raw)
In-Reply-To: <A3AC4FA47DC0B1458C3E5396E685E63302395C55@SAB-DC1.sab.uiuc.edu>
References: <A3AC4FA47DC0B1458C3E5396E685E63302395C55@SAB-DC1.sab.uiuc.edu>
Campbell, Lance wrote:
> I want to log all SQL commands as an executable script file for use in
> performance testing. Currently there is a lot of information in the log
> that is generated that would not be executable. Below is an example of
> what I would want to see; which is just the SQL.
>
>
>
> Example of log output:
>
> Select a,b,c from calendar where a=12;
>
> Select a,b,c from calendar where a=13;
>
>
Hi,
Wouldn't SQL statements in log possible be out of order, also transaction info
would be missing?
Even if you do it in application-side, logging query start time and transaction
info, and feed this data to some application that starts to excecute them in
correct time and context, you wouldnt be able to reliably replicate exact
behavior, cause configuration change might change query times too much.
But i see it _can_ be useful in some cases.
Rigmor
>
>
>
> How do I do this?
>
>
>
> Thanks,
>
>
>
>
>
>
>
> Lance Campbell
>
> Project Manager/Software Architect
>
> Web Services at Public Affairs
>
> University of Illinois
>
> 217.333.0382
>
> http://webservices.uiuc.edu
>
>
>
> !DSPAM:5,45b7c785287772091230466!
--
Rigmor Ukuhe
Finestmedia Ltd | Software Development Team Manager
gsm : (+372)56467729 | tel : (+372)6558043 | e-mail : rigmor.ukuhe@finestmedia.ee
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: rigmor.ukuhe@finestmedia.ee
Subject: Re: Logging just SQL commands in an SQL script format
In-Reply-To: <45B8AED5.3090905@finestmedia.ee>
References: <A3AC4FA47DC0B1458C3E5396E685E63302395C55@SAB-DC1.sab.uiuc.edu> <45B8AED5.3090905@finestmedia.ee>
* 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