Re: SQL code -246, ISAM code -154 problem.
Posted in 1997
Peter Jennings wrote: > > Running OnLine V5.0 under AIX. > We have a begin/commit process that locks a > parent record by updating a column with its > current contents. We find that if two users > try to update different rows in the same child > table, the first will suceed and the other fail > with SQL code -246, ISAM code -154. > The two users are accessing different rows > in both the parent and the child tables. > This only happens if the first user has not > reached the 'commit' before the second user > trys to update. > Both the tables have row mode locking set. > > 1st User User 2 > begin work begin work > lock parent row x lock parent row y > . . > . . > update child row m . > . update child row n (fails) > . . > . . > commit . > update child row n (OK) > . > commit > > Peter Jennings. Thanks to all those who posted ideas. It now looks as if this was a manefestation of the adjacent record locking 'feechur' of Informix 5.0, as explained by Gregg Knight. We had recently added the row locking coupled with begin work / commit / rollback in order to prevent two or more users accessing the same set of records. Until we upgrade to Version 7 we will just have to work round it. Peter Jennings.