Re: Locking
Posted in 1996
Chao Y. Din — — source: Informix-list mailing list archive (1991-1998)
Weimin Yang wrote: > > Reijer Koopsen wrote: > > > > If I get a row with the select for update statement > > I want that every other connection gets an error message > > when the select the same row for update, not read only. > > > 1. ... > 2. ... > 3. Do a dummy update of the row you want to lock, e.g., > rdoConnection.execute "update yourtabel set column=knownvalue where > column=knownvalue"; But Reijer said "not read only." My interpretation of his post is: others can read the row but not update the row. As long as you don't set the transation isolation level to dirty read, you should be able to use read lock which can be changed to write lock when the update statement is executed. Chao