lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <e...@ehatchersolutions.com>
Subject Re: Indexing Forums (Document & Field Paradigm)
Date Mon, 27 Jun 2005 23:54:43 GMT
Simply storing a parentId doesn't help query the hierarchy though -  
for example, search for all "lucene" containing documents in a  
specific forum thread, children and all.

One technique I've used to index hierarchy is to come up with a path  
string such as "/parent/child/grandchild" and index that as a non- 
tokenized field.  Querying for all documents under "/parent" is as  
simple as a PrefixQuery.

     Erik


On Jun 27, 2005, at 3:09 PM, Dan Funk wrote:

> You could have a parentId field in each document - which will give  
> you a nice hierarchy.  You could also create a topicId (Linux,  
> Microsoft, etc...) and a storyId.  At that point you can quickly  
> identify the topic and story for the message - and you can also  
> search within a specific thread (AND parentId=X)  or a particular  
> topic, or a particular story.
>
>
> Yousef Ourabi wrote:
>
>
>> Hello:
>> Thanks for all the help so far it has been fantastic. I have a
>> question on the document and field paradigm, this works great for
>> flat-files, like a word document, or web-page but what about nested
>> forums (ala slashdot) where in theory a specifc chat thread is nested
>> or is nested inside another chat thread.  Is there a way to nest
>> lucene documents. IE Top level post in forum is one document, and any
>> branches off the main thred are nested inside that top level one? OR
>> is there a better mapping of lucene's paradigms to a slashdot like
>> forums paradigm?
>>
>> Thanks for any help.
>>
>> Best,
>> Yousef
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
>> For additional commands, e-mail: java-user-help@lucene.apache.org
>>
>>
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message