Subject RE: [IBO] TIBOTable.Locate issue
Author IBO Support List
Hmmm.... IB Objects will bring additional records into the buffer when
necessary. However, prior to doing that, it will perform a select against
the server to see if the record meets the query criteria, including filters,
ranges, etc. If that responds in the negative then it won't bother fetching
in additional rows and just return false. I suspect there is something
unique to your situation that is throwing it off somehow. Would you please
be able to send me a simple sample app of this so that I can look into it?
If I find a problem I will get it fixed ASAP and I will add it to my
regression testing app.

Jason Wharton

-----Original Message-----
From: [] On Behalf
Of masonwheeler
Sent: Saturday, April 13, 2013 10:41 PM
Subject: [IBO] TIBOTable.Locate issue

I've got a TIBOTable mapped to a DB table with 240 rows. I've got a routine
that iterates over a second table that has a FK to the first table, and
calls Locate on the FK value to do some processing. The FK relationship
ensures that the row will be there. For ID values from 1 to 135, it works,
but above 135, Locate returns False.

Looking into the code, it appears that the internal dataset has a list of
buffer nodes, and it loads the first 135 of them (why i35? That's a very
arbitrary number) and if Locate doesn't ask for a value that can be found in
this node list, it does not check to see if its node count <
self.RecordCount and fetch more from the server.

Calling Last on the TIBOTable before starting the iteration works as a
workaround, presumably because it forces it to load more data. Not sure how
much more it makes it load, and if this would simply cause a gap to start
showing up once the table in question has more than 270 rows.



IB Objects - direct, complete, custom connectivity to Firebird or InterBase
without the need for BDE, ODBC or any other layer.
___________________________________________________________________________ - your IBO community resource for Tech Info papers,
keyword-searchable FAQ, community code contributions and more !
Yahoo! Groups Links