RE: Recommended Lock Mode for heavy JDBC usage?
Posted in 2003
With eror 243 there is another code that tells you specifically what the problem is. Take the sql that was running and run it with E4GLEXPLAIN set. Do you have the correct indexes or have you run the correct update stats? How many other users are accessing this table at the same time? MW > -----Original Message----- > From: owner-informix-list@iiug.org > [mailto:owner-informix-list@iiug.org]On Behalf Of Anthony Presley > Sent: Wednesday, 28 May 2003 8:32 a.m. > To: informix-list@iiug.org > Subject: Recommended Lock Mode for heavy JDBC usage? > > > Sorry for the cross-post, but it applies in both places :-( > > I'm writing several database conversion utilities for a client, under > Informix 7.31.UD2, which run fairly well. > > However, during the conversion of some 56,000 rows, I've got about > twelve errors for "Could not position within a table > (anthony.milestonedef). -243". Error -243, but it recommends looking > at OS errors, if not there, then ensure that the table's aren't > corrupted. > > My tables are not corrupted, nor is anything wrong with the hardware. > However, if I run the program by limiting the number of fetches to the > new database (SELECT statements), or by limiting the number of rows > converted at a time, it runs without errors. > > I'm accessing everything through JDBC, and my conversion routines are > all done in Java. My lock mode is set to row, and I've placed within > my routines the statements: "SET LOCK MODE TO WAIT", and I'm still > getting these errors. > > As a test, I ran a Java program which queries the database and yanks > some 65,000 rows from it. About half-way through, I get the same > error, and it dies. However, while watching the memory, it never uses > everything it has at its disposal, so I assume the problem is LIKELY > with the db, or JDBC driver. > > What can be done, if anything, about this? Is there a recommended > "lock mode"? How can I force the Informix JDBC driver to WAIT (if > that's the problem)? > > Thanks. > > --Anthony