[dev] [patch] sizelimit in turba sql driver.

Chuck Hagenbuch chuck at horde.org
Mon May 26 17:46:33 PDT 2003


Quoting Marko Djukic <marko at oblo.com>:

> i believe the paging would have to be done at the php level and not at
> the backend level, for two reasons:
> a) to avoid multiple queries to the backend (total results, then the
> section we are interested)

Why total results first? And if you're doing all results at once and caching
them, when do you update the cache (thus fetching everything again). Also,
if there are a lot of results, but you only need one - you'll never fetch
the whole result set if you just fetch the first slice in the backend.

And storing everything puts an extra load on *some* backend, even if it's
not a different one - if we store it in a cache, we have to hit the cache
*plus* the backend at least once. Etc.

> b) discrepancies with how different backends would handle paging, so i
> would rather have consistent results and handle it at the php level.

Are you just assuming that there would be discrepancies, or are you aware of
specific ones? Also, if we can do it in the backend, isn't it still a win
to  implement paging in the backends that support it, and emulate it in PHP
for those that don't?

> and since we are getting the total results anyway

We are? Why?

-chuck

--
Charles Hagenbuch, <chuck at horde.org>
The alligators were there, too, in a bathtub inside the house.



More information about the dev mailing list