Dieter Maurer wrote:
should return objects that have both "foo" AND "bar". In my case, no objects with "bar", but with "foo" a lot. The expr above returns ALL objects with "foo". Is it expected behavior?
A really long standing bug...
Is there a collector entry for this?
cheers,
Chris
Dear Chris, this is an "already discussed issue" :) http://www.dzug.org/mailinglisten/zope-org-zope/archive/2003/2003-12/1070709...
The ZCatalog treats an empty *string* in a special way to support[...] "AND"[...]
I've solved it in /PluginIndexes/common/util.py. When the param is a record, around line 95, I've added: if keys == ['']: keys = None Is it correct? Seems to work with all indexes I've and KeywordIndexes, which works also with AND as operator. --- Note: you also have to use lines to use the KeywordIndex: <textarea name="COLL:lines"></textarea> That was my solution. I think the "ManagableIndex" with the KeywordIndex replacement should be added, maybe calling it KeywordIndexNG :)