[Date Prev][Date Next] [Chronological] [Thread] [Top]

RE: server side sorting & paging?

When that single "client" is a server generating dynamically generated web
pages using those results for multiple HTTP clients, then it becomes a

In any case, its apparent you have no intention of implementing server side
sorting as most commercial LDAP offerings have done (as per the rfc that was
mentioned). Thats all I needed to know. I guess we will have to stick with
some form of caching, as was suggested earlier.

-----Original Message-----
From: Howard Chu [mailto:hyc@highlandsun.com]
Sent: 23 April 2004 13:50
To: 'Jon Poulton'; openldap-software@OpenLDAP.org
Subject: RE: server side sorting & paging?

> -----Original Message-----
> From: owner-openldap-software@OpenLDAP.org
> [mailto:owner-openldap-software@OpenLDAP.org]On Behalf Of Jon Poulton

> The crux of the problem is: If I have 1000 results for "A" and I want
> to display these in alphabetical order 1 page at a time-
> currently I have
> to sort ALL the results IN MEMORY before retreiving only ONE
> PAGE from the 1000
> things I just sorted. OK?

Even a 20 MHz '286 can sort 1000 entries in less than 100 milliseconds. It
trivial for a single client to sort 1000 entries on the fly. For a single
server to sort millions of entries for hundreds of clients at once, however,
is another thing entirely.

> >>I believe LDAP is intended to be a large-scale distributed
> information
> >>storage/retrieval mechanism.

> And as such I would expect it to return results from a query
> in some sort
> of clearly defined order. It doesnt.

I'm not sure where this expectation comes from, but nowhere in any edition
the X.500 protocol spec or any version of the LDAP spec is anything like
promised. In fact, certain portions of the spec explicitly state that
must not assume anything about the ordering of returned results.

>   -- Howard Chu
>   Chief Architect, Symas Corp.       Director, Highland Sun
>   http://www.symas.com               http://highlandsun.com/hyc
>   Symas: Premier OpenSource Development and Support