[Zope] Searching a FieldIndex for prefix or OR
   
    Chris McDonough
     
    chrism@digicool.com
       
    Mon, 02 Apr 2001 23:50:57 -0400
    
    
  
"Randall F. Kern" wrote:
> 
> Is it possible to search a catalog on a field index for either a given
> prefix, or any of a list of values?
> 
> Maybe I'm going about this wrong; I want to add the ability to only show
> objects found below a specific place on my site, and to do that I
> created a field index on the path to each object.  Then at query time I
> would like to search for /foo/bar/*, or failing that create a list of
> all paths below /foo/bar and create an OR query.
> 
> The solution I'm using now is to post-process the search results, but
> that seems lame :)
Yes, it is lame.  And no, it's not possible with a FieldIndex.  ;-)
There's a proposal floating around verbally at DC to create a
"PathIndex" that has this behavior.  I think Tres actually sent me some
code for it at some point.  You want that I should look it up and send
it to you?
- C