How do I use Examine to Merge Node Data and Media Data into a single Lucene document
I have media (PDFs) that I want indexed in lucene, however I want to merge some data from the content where they're attached.
1) I want to take the 'path' from the content node where it's attached and include it in the lucene document so that I can search parts of the sub-tree for those attachments.
2) include the nodeTypeAlias from the content node in order to filter on this also.
Documents may need to be indexed more than once if attached at more than one place
Note: I want separate results for pdf and content node, so I don't want to merge them completely.
In umbraco 4.0.3 we had a buggy hack to manually create lucene docuemnts by calling the following:
I think we can drop the idea that docuements need to be indexed more than once, because we can simple concatenate the paths into one field on the same lucene document, we only use this data like so
How do I use Examine to Merge Node Data and Media Data into a single Lucene document
I have media (PDFs) that I want indexed in lucene, however I want to merge some data from the content where they're attached.
1) I want to take the 'path' from the content node where it's attached and include it in the lucene document so that I can search parts of the sub-tree for those attachments.
2) include the nodeTypeAlias from the content node in order to filter on this also.
Documents may need to be indexed more than once if attached at more than one place
Note: I want separate results for pdf and content node, so I don't want to merge them completely.
In umbraco 4.0.3 we had a buggy hack to manually create lucene docuemnts by calling the following:
this.SaveDeleteIndexQueueItem(new KeyValuePair(IndexNodeIdFieldName, media.Id.ToString()));
I think we can drop the idea that docuements need to be indexed more than once, because we can simple concatenate the paths into one field on the same lucene document, we only use this data like so
Ditto for the nodeTypeAlias
is working on a reply...