Hi, Spencer Why not translating a xml to an object when indexing,and translating the object to a xml when searching.
kai -----邮件原件----- 发件人: Spencer Tickner [mailto:[EMAIL PROTECTED] 发送时间: 2007年8月4日 星期六 6:01 收件人: java-user@lucene.apache.org 主题: Nested Fields Hi, and thanks in advace for any help. I'm fairly new to lucene so excuse the ignorance. I'm attempting to field an XML documents with nested fields. So: <foo> <bar>This</bar> <bat>That</bat> </foo> would give me hits for: bar:This bat:That foo:ThisThat The only way I can see a way of doing this now is to field each element I want to field and all of it's descendant text, repeating the same text multiple times for nested fields, then finally have a <root> field that would field the text for all the document so users not doing field searches would programmically be forced to search on <root> to not get multiple hits. This seems inefficent to me and am hopeing that someone has some advice or can point me to a better way. Thanks, Spencer --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]