yes, positioning and count are the problems.
I am aware of the platform setting for count - I wrote it! ;-)
I am trying to determine better what is causing the problem with
DB2 - it appears that it is not set to use the new count, and then
fails to count correctly using the last();getRow() method, 
which causes RsIterator to assume that it is not JDBC 2.0 compliant
and internally to RsIterator changes this assumption to !2.0 (incorrect
in my thinking - if 2.0 works for everything else....)

Also, the "alternative count" method could be applied for non-2.0 drivers
in otherwords in RsIterator 
if !supportsAdvancedJDBCCursorControl ||
Platform.useCountForResultsetSize())
  use count
else 
  use last/getRow

I will submit a patch for this shortly...

Thanks

> -----Original Message-----
> From: Matthew Baird [mailto:[EMAIL PROTECTED]]
> Sent: Monday, October 07, 2002 10:26 AM
> To: OJB Users List
> Subject: RE: DB2 usage and concerns
> 
> 
> Hi Russel,
> 
> I think the parts of OJB you are talking about have to do 
> with finding the count and positioning the cursor.
> 
> There is a platform setting for alternative count methods.
> 
> If your driver does not support .absolute, then you can't use 
> cursor positioning, and therefore must step through the 
> resultset to position your cursor (or maybe there is a sql 
> command for db2? let me know if there is).
> 
> There is no platform dependent behaviour for cursor 
> positioning, but it could be implemented if needed. I don't 
> have a DB2 Instance setup, so I can't currently test. so the 
> org.apache.ojb.broker.query.Query.setStartAtIndex/setEndAtInde
> x functionality you want to use will not be supported in db2 
> right now. Can you explain how you do this in raw jdbc on db2?
> 
> m
> 
> -----Original Message-----
> From: Russell Smyth [mailto:[EMAIL PROTECTED]]
> Sent: Monday, October 07, 2002 10:26 AM
> To: 'OJB Users List'
> Subject: RE: DB2 usage and concerns
> 
> 
> Thank you Marcos for the response, but I have already done this.
> I will try to furnish some more info. I am guessing that I may
> be pushing some limits/limitations more than others (typical for me!)
> 
> > -----Original Message-----
> > From: Marcos Oliva [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, October 07, 2002 10:23 AM
> > To: 'OJB Users List'
> > Subject: RE: DB2 usage and concerns
> > 
> > 
> > Russel, 
> > 
> > For DB2 JDBC 2.0 , there is a command under 
> > sqllib\java12\usejdbc2.bat or sh
> > 
> > this will change the driver from 1.x to 2.0 JDBC, now take 
> the newly 
> > updated driver file db2java.zip and added to your OJB lib 
> > directory , I
> > think
> > this should help on that.
> > 
> > I have used DB2 7.2 (FixPack 3.0) to test some OJB builds 
> and they are
> > working as a JDBC2.0
> > 
> > my 2 cents
> > 
> > marcos oliva
> > 
> > -----Original Message-----
> > From: Russell Smyth [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, October 07, 2002 10:18 AM
> > To: OJB Users List (E-mail)
> > Subject: DB2 usage and concerns
> > 
> > 
> > I have some questions for those of you using OJB with IBM DB2 7.x.
> > It will be a requirement of my project to be able to work 
> > (well) with DB2, 
> > however, I have already run into some problems.
> > 
> > It appears that OJB does not support DB2 as a JDBC 2.0 
> > database, but only
> > as a 1.X db. Is this true? I would assume it is due to some 
> incomplete
> > support in DB2 (ie ResultSet.last() and ResultSet.absolute() 
> > are inconsitent
> > with the OJB assumptions)
> > 
> > For those using DB2 in applictations, without JDBC 2, you cannot do 
> > 
> org.apache.ojb.broker.query.Query.setStartAtIndex/setEndAtIndex. Does
> > anyone have a (clean) workaround?
> > 
> > Is anyone using an alternative DB2 JDBC 2 Driver that would 
> > allow using
> > OJB in JDBC 2 mode?
> > 
> > Thanks in advance
> > Russell
> > 
> > --
> > To unsubscribe, e-mail:   
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: 
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to