Hi,
org@kewlstuff.co.za wrote:
> Ha ha... thx Tino
> Yes, I think this is way to go, strange how my mind climbs the wrong
> tree sometimes :)
> I actually need to aquire a transaction across several dB's, check if
> the conditions are right, and then modify some tables, write and remove
> some triggers.
> Transactions in postgres are 2 sophisticated, I dont think they will
> hold the locks at the level I need them.
You want to read about explicit locking:
http://www.postgresql.org/docs/8.2/static/explicit-locking.html
> But I was thinking (climbing out of the wrong tree;)... I can just
> aquire exclusive locks on the tables, and hey presto, users are on hold
> while the software checks the dB's.
I'm sure, that's possible. However, I remember you were talking about
replication, thus I have to add a warning: please keep in mind that this
does not scale. You're most probably better using two phase commit,
aren't you?
Regards
Markus