In response to Janning Vygen <vygen@xxxxxxxxxxx>: > hi, > > http://archives.postgresql.org/pgsql-general/2009-03/msg00581.php > > This was my suggestion about introducing a statment to get a sample of SQL > statements. Nobody answered yet. Why not? i think my suggestion would help a > lot. Or was it kind of stupid? For my part, I don't think this would be useful. Since most of your queries are run by software, you're going to see a fairly predictable pattern to the queries, which means your sampling isn't going to be anywhere near random, thus it will still be inaccurate and incomplete. In my experience, I've found that enabling full logging for a short time (perhaps a few hours) gathers enough data to run through tools like pgFouine and find problem areas. Also, we have development servers that run automated tests, and since it's not critical that they be performant, we can run full query logging on them all the time. Additionally, we make sure our production systems have enough hardware behind them that we can add additional tasks without it affecting production use. All of these are (in my opinion) better approaches to the problem than yet another arbitrary query filtering technique. I mean, logging only the most time-consuming queries is already arbitrary enough (as you already stated). -- Bill Moran http://www.potentialtech.com http://people.collaborativefusion.com/~wmoran/ -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general