Could not do a physical-order read to fetch next row.
Posted in 2006
A Java/Hibernate app on IDS 9.4 got "Could not do a physical-order read to fetch next row" (SQL -244), apparently a locking problem; switching the table to ROW lock mode didn't help. Respondents suggested the app's update and select run as separate sessions, so the select hits rows still locked by the uncommitted transaction, and recommended using dirty read isolation (e.g. st.execute("SET ISOLATION TO DIRTY READ")). The poster then asked where to put this in Hibernate, and no answer to that is recorded.
Auto-generated by DrWatson from the posts below — may be imperfect; read the full thread.
Topics: Java & JDBC Development, Versions, Editions & End-of-Life
Hi All, I am geetting an Error as "Caused by: java.sql.SQLException: Could not do a physical-order read to fetch next row." . Database used is IDS 9.4 . One table is getting locked . Even after changing the LOCK MODE to ROW the problem is persisting. What can be the solution for the same. Please reply to me asap. Thanks Rakesh.
could it be possible that 2 different sessions are locking the same row rakesh_sa@yahoo.com wrote: > Hi All, > > I am geetting an Error as "Caused by: java.sql.SQLException: Could not > do a physical-order read to fetch next row." . Database used is IDS 9.4 > . One table is getting locked . Even after changing the LOCK MODE to > ROW the problem is persisting. What can be the solution for the same. > > Please reply to me asap. > > Thanks > Rakesh.
No , it is a single session in which i am saving some transaction . At this point of time the record is getting locked . When i try to view the saved data i get this error. scottishpoet wrote: > could it be possible that 2 different sessions are locking the same row > > > rakesh_sa@yahoo.com wrote: > > Hi All, > > > > I am geetting an Error as "Caused by: java.sql.SQLException: Could not > > do a physical-order read to fetch next row." . Database used is IDS 9.4 > > . One table is getting locked . Even after changing the LOCK MODE to > > ROW the problem is persisting. What can be the solution for the same. > > > > Please reply to me asap. > > > > Thanks > > Rakesh.
looks like your java app is treating the update and the select as 2 seperate sessions so the select of the data believes the row is locked .. presumably by the record that has updated it change the app to do dirty read rather than commited read (the default isolation strategy) and the select should work. rakesh_sa@yahoo.com wrote: > No , it is a single session in which i am saving some transaction . At > this point of time > the record is getting locked . When i try to view the saved data i get > this error. > > scottishpoet wrote: > > > could it be possible that 2 different sessions are locking the same row > > > > > > rakesh_sa@yahoo.com wrote: > > > Hi All, > > > > > > I am geetting an Error as "Caused by: java.sql.SQLException: Could not > > > do a physical-order read to fetch next row." . Database used is IDS 9.4 > > > . One table is getting locked . Even after changing the LOCK MODE to > > > ROW the problem is persisting. What can be the solution for the same. > > > > > > Please reply to me asap. > > > > > > Thanks > > > Rakesh.
In java Execute the following command st.execute ("SET ISOLATION TO DIRTY READ"); On 19 Jul 2006 04:09:41 -0700, scottishpoet <dryburghj@yahoo.com> wrote: > looks like your java app is treating the update and the select as 2 > seperate sessions so the select of the data believes the row is locked > .. presumably by the record that has updated it > > change the app to do dirty read rather than commited read (the default > isolation strategy) and the select should work. > > > > rakesh_sa@yahoo.com wrote: > > No , it is a single session in which i am saving some transaction . At > > this point of time > > the record is getting locked . When i try to view the saved data i get > > this error. > > > > scottishpoet wrote: > > > > > could it be possible that 2 different sessions are locking the same row > > > > > > > > > rakesh_sa@yahoo.com wrote: > > > > Hi All, > > > > > > > > I am geetting an Error as "Caused by: java.sql.SQLException: Could not > > > > do a physical-order read to fetch next row." . Database used is IDS > 9.4 > > > > . One table is getting locked . Even after changing the LOCK MODE to > > > > ROW the problem is persisting. What can be the solution for the same. > > > > > > > > Please reply to me asap. > > > > > > > > Thanks > > > > Rakesh. > > _______________________________________________ > Informix-list mailing list > Informix-list@iiug.org > http://www.iiug.org/mailman/listinfo/informix-list > -- Regards, Prateek Jain
We have an Hibernate application which is accessing Informix . Could you let me know on where in hibernate query i have to execute the st.execute statement. Thanks Rakesh Jain. Prateek Jain wrote: > In java > Execute the following command > st.execute ("SET ISOLATION TO DIRTY READ"); > > On 19 Jul 2006 04:09:41 -0700, scottishpoet <dryburghj@yahoo.com> wrote: > > looks like your java app is treating the update and the select as 2 > > seperate sessions so the select of the data believes the row is locked > > .. presumably by the record that has updated it > > > > change the app to do dirty read rather than commited read (the default > > isolation strategy) and the select should work. > > > > > > > > rakesh_sa@yahoo.com wrote: > > > No , it is a single session in which i am saving some transaction . At > > > this point of time > > > the record is getting locked . When i try to view the saved data i get > > > this error. > > > > > > scottishpoet wrote: > > > > > > > could it be possible that 2 different sessions are locking the same row > > > > > > > > > > > > rakesh_sa@yahoo.com wrote: > > > > > Hi All, > > > > > > > > > > I am geetting an Error as "Caused by: java.sql.SQLException: Could not > > > > > do a physical-order read to fetch next row." . Database used is IDS > > 9.4 > > > > > . One table is getting locked . Even after changing the LOCK MODE to > > > > > ROW the problem is persisting. What can be the solution for the same. > > > > > > > > > > Please reply to me asap. > > > > > > > > > > Thanks > > > > > Rakesh. > > > > _______________________________________________ > > Informix-list mailing list > > Informix-list@iiug.org > > http://www.iiug.org/mailman/listinfo/informix-list > > > > > -- > Regards, > Prateek Jain