pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Graham Leggett <minfrin@sharp.fm>
To: pgsql-jdbc@postgresql.org
Subject: Picking up strange queries for "pg_catalog"
Date: Sun, 4 Jul 2010 13:13:49 +0200
Message-ID: <D1BEEF82-02F2-4CFD-BBD3-EA0AFFA0AFF8@sharp.fm> (raw)

Hi all,

While investigating some performance issues with a database, I have  
been analysing the database queries, and have discovered that I am  
getting thousands and thousands of queries that look like the ones  
below.

Asking on the pgsql-general list, I was pointed in the direction of  
the jdbc driver, which in theory is making these queries, but not  
caching them.

Does this look familiar to anybody?

In addition to this, I am using the atomikos XA transaction manager,  
could this be the source of these queries?

Is there anything I can do to stop these queries being made?

2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT attnotnull  
FROM pg_catalog.pg_attribute WHERE attrelid = $1 AND attnum = $2
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '4'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT def.adsrc  
FROM pg_catalog.pg_class c JOIN pg_catalog.pg_attribute a ON  
(a.attrelid=c.oid) LEFT JOIN pg_catalog.pg_attrdef def ON  
(a.attrelid=def.adrelid AND a.attnum = def.adnum) WHERE c.oid = $1 and  
a.attnum = $2 AND def.adsrc LIKE '%nextval(%'
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '4'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT attnotnull  
FROM pg_catalog.pg_attribute WHERE attrelid = $1 AND attnum = $2
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '5'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT def.adsrc  
FROM pg_catalog.pg_class c JOIN pg_catalog.pg_attribute a ON  
(a.attrelid=c.oid) LEFT JOIN pg_catalog.pg_attrdef def ON  
(a.attrelid=def.adrelid AND a.attnum = def.adnum) WHERE c.oid = $1 and  
a.attnum = $2 AND def.adsrc LIKE '%nextval(%'
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '5'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT attnotnull  
FROM pg_catalog.pg_attribute WHERE attrelid = $1 AND attnum = $2
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '8'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT def.adsrc  
FROM pg_catalog.pg_class c JOIN pg_catalog.pg_attribute a ON  
(a.attrelid=c.oid) LEFT JOIN pg_catalog.pg_attrdef def ON  
(a.attrelid=def.adrelid AND a.attnum = def.adnum) WHERE c.oid = $1 and  
a.attnum = $2 AND def.adsrc LIKE '%nextval(%'
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '8'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT attnotnull  
FROM pg_catalog.pg_attribute WHERE attrelid = $1 AND attnum = $2
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '9'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT def.adsrc  
FROM pg_catalog.pg_class c JOIN pg_catalog.pg_attribute a ON  
(a.attrelid=c.oid) LEFT JOIN pg_catalog.pg_attrdef def ON  
(a.attrelid=def.adrelid AND a.attnum = def.adnum) WHERE c.oid = $1 and  
a.attnum = $2 AND def.adsrc LIKE '%nextval(%'
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '9'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT attnotnull  
FROM pg_catalog.pg_attribute WHERE attrelid = $1 AND attnum = $2
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '7'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT def.adsrc  
FROM pg_catalog.pg_class c JOIN pg_catalog.pg_attribute a ON  
(a.attrelid=c.oid) LEFT JOIN pg_catalog.pg_attrdef def ON  
(a.attrelid=def.adrelid AND a.attnum = def.adnum) WHERE c.oid = $1 and  
a.attnum = $2 AND def.adsrc LIKE '%nextval(%'
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '7'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT attnotnull  
FROM pg_catalog.pg_attribute WHERE attrelid = $1 AND attnum = $2
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '10'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT def.adsrc  
FROM pg_catalog.pg_class c JOIN pg_catalog.pg_attribute a ON  
(a.attrelid=c.oid) LEFT JOIN pg_catalog.pg_attrdef def ON  
(a.attrelid=def.adrelid AND a.attnum = def.adnum) WHERE c.oid = $1 and  
a.attnum = $2 AND def.adsrc LIKE '%nextval(%'
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '10'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT attnotnull  
FROM pg_catalog.pg_attribute WHERE attrelid = $1 AND attnum = $2
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '6'
2010-07-03 23:49:31 SAST LOG:  execute <unnamed>: SELECT def.adsrc  
FROM pg_catalog.pg_class c JOIN pg_catalog.pg_attribute a ON  
(a.attrelid=c.oid) LEFT JOIN pg_catalog.pg_attrdef def ON  
(a.attrelid=def.adrelid AND a.attnum = def.adnum) WHERE c.oid = $1 and  
a.attnum = $2 AND def.adsrc LIKE '%nextval(%'
2010-07-03 23:49:31 SAST DETAIL:  parameters: $1 = '29427', $2 = '6'

Regards,
Graham
--




view thread (3+ messages)  latest in thread

Message-ID: <D1BEEF82-02F2-4CFD-BBD3-EA0AFFA0AFF8@sharp.fm>
Permalink:  ../D1BEEF82-02F2-4CFD-BBD3-EA0AFFA0AFF8@sharp.fm/
Also on:    postgresql.org/message-id/D1BEEF82-02F2-4CFD-BBD3-EA0AFFA0AFF8@sharp.fm

 · 

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-jdbc@postgresql.org
  Cc: minfrin@sharp.fm
  Subject: Re: Picking up strange queries for "pg_catalog"
  In-Reply-To: <D1BEEF82-02F2-4CFD-BBD3-EA0AFFA0AFF8@sharp.fm>
  References: <D1BEEF82-02F2-4CFD-BBD3-EA0AFFA0AFF8@sharp.fm>

* 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