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

DatabaseMetaData and Transactions

From: Carl Olivier <carl(at)zero-one(dot)co(dot)za>
To: pgsql-jdbc(at)postgresql(dot)org
Subject: DatabaseMetaData and Transactions
Date: 2005-06-06 13:38:16
Message-ID: 473185057AB4D7118B6C00508B624DDA1C968D@ALPHENPDC (view raw or flat)
Thread:
Lists: pgsql-jdbc
Greetings.

Having a problem with regards DatabaseMetaData retrievals within a
Transaction.  I have a large transaction running - within which database
alterations need to occur.  However, during this process I need to retrieve
Table metadata (via the DatabaseMetaData.getTables() method).  However, this
does not seem possible in POSTGRES?  I receive the following error:

ERROR: current transaction is aborted, queries ignored until end of
transaction block.

I trace that directly to a call to the getTables method of the
DatabaseMetaData implementation.

Can anyone provide me with any advice here?  Is this correct behaviour, and
is there any way (other than caching table metadata prior to, and
maintaining said cache during the transaction) to allow for meta data
retrieval during a transaction?

Thanks in advance!

Regards,

Carl

Responses

pgsql-jdbc by date

Next:From: Dave CramerDate: 2005-06-06 14:23:12
Subject: Re: DatabaseMetaData and Transactions
Previous:From: Kris JurkaDate: 2005-06-05 19:57:15
Subject: Re: italian translation

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