| From: | Patrice Espié <patrice(dot)espie(at)univ-lyon2(dot)fr> |
|---|---|
| To: | <pgsql-novice(at)postgresql(dot)org> |
| Subject: | Lock : How to know if a row is locked ? |
| Date: | 2001-04-10 12:34:34 |
| Message-ID: | 006501c0c1ba$99845bc0$0400a8c0@univlyon2.fr |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-novice |
Hello,
I know SELECT ... FOR UPDATE, but if a row is cirrently locked, my user will
wait until the row is unlocked ... perhaps one hour if the other user (the
'locker' one) is taking a bath :)
Here are my two questions :
.o. How could I know if a row is locked before doing a SELECT ... FOR UPDATE
?
.o. Using an ODBC interface (under Windows), how could I get a timeout
(knowing that SQLSetStmtAttr( m_hStmt, SQL_ATTR_QUERY_TIMEOUT,
(void*)SecondTimeOut, SQL_IS_INTEGER ) doesn't works...) which stops (break
?) the SELECT or other SQL order ?
Thanks
Patrice Espié
--
Le Monde, c'est comme un éléphant
qui va à la pêche
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Patrice Espié | 2001-04-10 14:30:18 | Buggy SELEC ... FROM UPDATE ? |
| Previous Message | manoj garg | 2001-04-10 11:15:39 | how to run postgre on winNT |