From: | Daniel Michał <danielosch(at)o2(dot)pl> |
---|---|
To: | <pgsql-admin(at)postgresql(dot)org> |
Subject: | postgresql and lock an row |
Date: | 2003-08-28 12:28:49 |
Message-ID: | 002201c36d5f$efd76fa0$2601a8c0@gliwice.helion.com.pl |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Hallo everybody,
I have a problem that I can not to solve in a simple way. I wrote a message to pgsql-sql(at)postgresql(dot)org but "I can get no satisfaction". Maybe You help me please :-)....
This is my problem....
SOME INFORMATION:
I have a postgresql database version 7.2.2 on Linux platform. I communicate with Postgresql from a Delphi application using microolap drivers and everything works fine.
PROBLEM DESCRIPTION:
I have to lock one row in table1 for user1. In the same time other users should be able to read this record but when other user for example user2 want to edit this record user2 should get information "The row you try to edit is currently edit" - or sometihing similar.
Of course I can lock record with syntax "Begin; select * from table1 where ID=12 for update; update table1 set field1="New value" where ID=12; commit;"
but I can not to inform other user that the record is edited?
MAIN TARGET:
How to get information that current record is edited? Which function can I use?
Please help me, Maybe someone have similar problem?
Greetings,
Daniel
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2003-08-28 13:33:17 | Re: plpgsql: Bush becomes a null, can not execute null query |
Previous Message | Bruno LEVEQUE | 2003-08-28 12:16:24 | Re: How do i get the location or -D paramter to accept a windows |