FetchWholeRows property

Applies to
TIB_BDataset

Declaration
Property FetchWholeRows : boolean;

Description
This feature is designed to allow the limitations of the buffered query to handle all types of SELECT statements.

It makes it so that the query is processed like the Delphi TQuery where the whole rows are fetched instead of doing the keys and then the individual rows.

You set FetchWholeRows to false only when you are dealing with a very large dataset (both rows and cols) and the user wants to scroll around in it at random and do refreshes, etc. You really should also have a small key like a single integer column too. Scrolling at random means doing Locate()'s, IncSearches, etc. A KeyLinks child table that is large in rows would do well to have split buffering to. This way it will only have to fetch keys to get to the desired record if it is not already in the buffer.

The downsides to this setting is that you have three cursors instead of one and the records are not able to be batched up into a single network packet. They come one at a time which overall is much more enefficient if you end up fetching the whole dataset in.

Otherwise, you are better off leaving it to true so that IB can batch up records together in a packet for crossing the wire more efficiently and tell them to use the search mode rather than scrolling around. Entering search criteria is more accurate and offloads work to the server more efficiently.

The rule of thumb is this. If you expect to fetch 1/3 or more of the dataset then use FetchWholeRows as true. Otherwise, if you have a small key and a wide row and will only be peeking at small slices of the dataset then set it to false.