From: Wolfgang M. <wol...@ex...> - 2010-03-19 19:48:07
|
>> @Roy: I like this approach but how efficient it is? I would have to do this >> recursively through the entire database. Seems like it might bog down the >> system. > > It's a good question, but for me in the sandbox I'm getting nearly > instantaneous results. I think it should work well if you don't have more than maybe a hundred collections and a few thousand documents. > Wolfgang - does the contains() in Roy's script take advantage of the > collections or structural indexes? No. eXist does have an index on all collection paths, but not on the documents. However, the collection tree will be in memory most of the time, so we could probably provide an extension function which does a quick search through the collection/document tree. This would at least be quicker than doing it manually in XQuery. > Or, theoretically, would it make > more sense to create a specialized ngram or lucene index for document > uris / filenames? Well, I thought about adding a facility which would allow us to create indexes on arbitrary data generated from a query. This could certainly be used for indexing document paths. Wolfgang |