Re: [Zope] ZCatalog - OR'ing on different colums (indices)
On Fri, 25 Aug 2000, Aleksander Salwa wrote: > Is there any better method of OR'ing on differend indices in quering > ZCatalog, then the method described in 'Advanced ZCatalog Searching' Ah, my solution obviously only works if all your fields are text indexes... --RDM ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] ZCatalog - OR'ing on different colums (indices)
On Fri, 25 Aug 2000, Aleksander Salwa wrote: > Is there any better method of OR'ing on differend indices in quering > ZCatalog, then the method described in 'Advanced ZCatalog Searching' > How-To: One way that works well but only works if you always do the same type of search (which it sounds like is true in your case) is to create a method for all of the objects that returns the concatenation of all of the data fields of intrest, and index that in the Catalog. You then search on the field, and return the relevant documents. Since the Catalog only stores word indexes and document indexes and not the text itself, this is not as inefficient as it sounds. It's also a little more execution-time efficient (which is good for a web ap) since you are effectively pre-computing the between-fields OR portion of the search. --RDM ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
[Zope] ZCatalog - OR'ing on different colums (indices)
Is there any better method of OR'ing on differend indices in quering ZCatalog, then the method described in 'Advanced ZCatalog Searching' How-To: ... This seems to me too expensive - here three searches are made. Is there - or should be added - any support for it in ZCatalog ? Another fault of this method are superfluous repetitions in results - if some catalogued object matches search pattern on more then one index. It seems to me to be common case, when we show to user simple search form with only one input (that is where 'userInput' came from) and 'Go!' button. User don't want to know, that we have our data splited in many properties. But on Zope side it's very good to have it structured in that way - so how to reconcile these things ? [EMAIL PROTECTED] /--\ | `long long long' is too long for GCC | \--/ ___ Zope maillist - [EMAIL PROTECTED] http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )