Subject Re: Firebird 1
> Right. So replace all of the x >= :x y >= :y with
> x > :x or x = :x
> and (y > :y or y = :y
> and (z >= :z))

Well, there you have the unique combined key :)

> For relatively small values of n and large values of
> g, it's not so bad. Retrieving 100 rows in groups of 10 requires
> reading 5500 rows. Clearly the developer can control that. And
> Firebird/InterBase developers are adults, capable of making
> choices. But it bugs me.

If one just discards the head and tail of the result set, wouldn't
the total time be n/g times that of each full query?

My experience with presentation of data that is mainly familiar to
the user (contact management lists of a few thousand people, lists of
legal categories) is that users prefer long ordered lists (on
multiple pages) which they can narrow down or reorder according to
different criteria. For example when a database of 5000 people is
displayed, they don't always want it separated into different pages
according to the alphabet. Why? Because when they narrow it down to
100, pages for some letters will contain only 3 or 4 entries.

Kind regards

Fred Toussi