Unix Technical Forum

Re: Transaction is read-only in auto commit mode

This is a discussion on Re: Transaction is read-only in auto commit mode within the pgsql Hackers forums, part of the PostgreSQL category; --> Chattopadhyay asked: > My application based on Java servlets was running fine with > version PostgreSQL 7.x, but started ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Hackers

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-12-2008, 06:00 AM
Albe Laurenz
 
Posts: n/a
Default Re: Transaction is read-only in auto commit mode

Chattopadhyay asked:
> My application based on Java servlets was running fine with
> version PostgreSQL 7.x, but started giving error:
> "transaction is read-only", in version 8.0 and 8.1. I am
> using Suse Linux 9.3/PostgreSQL 8.0 or Suse Linux
> 10.1/PostgreSQL 8.1. I am using JDBC 3 drivers and all
> connections are in auto-commit mode. Could you please tell me
> what's going wrong.

[...]
> I'd really appreciate if anyone could suggest a pointer for
> further investigation, if not an outright solution.


Via JDBC, ask the database to

SHOW default_transaction_read_only

and look at the output.
If that is 'true', look at

SELECT source FROM pg_settings WHERE
name='default_transaction_read_only'

If it is false, check java.sql.Connection.isReadOnly().
It is 'false' by default, but maybe is changed somewhere in your code.

Yours,
Laurenz Albe

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 01:09 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com