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

Re: OT: Question about transactions

From: "Richard Broersma" <richard(dot)broersma(at)gmail(dot)com>
To: "Paul Tomblin" <ptomblin(at)gmail(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: OT: Question about transactions
Date: 2008-08-12 20:21:53
Message-ID: 396486430808121321y1b65ba99q561c1a9fa820a1ae@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
On Tue, Aug 12, 2008 at 1:09 PM, Paul Tomblin <ptomblin(at)gmail(dot)com> wrote:

> is there a way for the other JVMs to get a consistent view
> of the database?

My understanding is that PostgreSQL only supports two forms of
transaction Isolation: READ COMMITED AND SERIALIZABLE.  This means
that only the client that has opened the transaction can see
un-commited data.  All other client instances will see only the
commited data.

>  For instance, if program 1 updates something in the
> database and commits, and then tells everybody that's it's updated,
> and then deletes the item from the database and commits, and then
> tells everybody that it's deleted,

I'm not to sure on this one.  If the other JVM are using a seperate
connection, I wouldn't expect you to be able to achieve consistant
results. However, maybe postgreSQL's LISTEN and NOTIFY will do what
you need?
http://www.postgresql.org/docs/8.3/interactive/sql-listen.html
http://www.postgresql.org/docs/8.3/interactive/sql-notify.html


-- 
Regards,
Richard Broersma Jr.

Visit the Los Angeles PostgreSQL Users Group (LAPUG)
http://pugs.postgresql.org/lapug

In response to

pgsql-jdbc by date

Next:From: Andrew SullivanDate: 2008-08-12 20:54:10
Subject: Re: OT: Question about transactions
Previous:From: Paul TomblinDate: 2008-08-12 20:13:01
Subject: PreparedStatement timeouts?

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