AdvancedQuery is a Zope product for flexible queries against "ZCatalog" or "CatalogTool".
Queries can be arbitrarily combined with "and", "or" and "not". All index types are almost fully supported (exception: relevance sorting of TextIndexes).
AdvancedQuery supports efficient incremental (lazy) multi-level sorting via FieldIndexes. This means, you can sort via e.g. "sort_on=(('Date','desc'), 'portal_type', 'id')". For large result sets, sorting is performed incrementally, only as far as you access the result. This can drastically speed up sorting time.
AdvancedQuery is especially efficient for "ManagableIndex"es (see: http://www.dieter.handshake.de/pyprojects/zope#ManagableIndex).
New in version 0.3:
* uses for CMF's "CatalogTool" an index ValidityRange (assumed to be a Managable RangeIndex) in preference of CMF's effective and expires indexes which can significantly improve query speed
More information and download:
http://www.dieter.handshake.de/pyprojects/zope#AdvancedQuery
Note: This may be the last version with its current open source unrestricted use license. I consider whether I will expressly forbid the use of my software by institutions of the European Union (Councel of Ministers, Commission, Parliament, ...). This is in protest against a recent decision of the Councel to make software patentable. This decision ignores a Parliament vote that pleaded to keep logic (algorithms, business rules) un-patentable.