Hello !
At least, I've had the oportunity to test your solution, Pieter, which was to use dynamic field : > <dynamicField name="page*" type="text" indexed="true" stored="true" /> > > Store each page in a separate field (e.g. page1, page2, page3 .. pageN) then > at query time, use the highlighting parameters to highlight matches in the > page fields. You should be able to determine the page field that matched the > query by observing the highlighted results (I'm not certain if the > hl.flparameter accepts dynamic field names, you may need to specify > them all > manually): > > hl=true&hl.fl=page1,page2,page3,pageN&hl.requireFieldMatch=true As expected, when using the option requireFieldMatch=true ; it does not work... But when the option is set to false, it seems to work fine, and in first thought, I don't need it... As you say, I need to specify each field when requesting the index... It's a big letdown, in my case : it's a shame because, your solution nearly answer my problem. It seems the highlights fields must be specified, and that I can't use the * completion to do so. Am I true ? Is there a way to go throught this obligation ? Anyway, thanks you very much ! Kind Regards, Pierre-Yves Landron > Date: Mon, 13 Aug 2007 21:57:42 +1000 > From: [EMAIL PROTECTED] > To: solr-user@lucene.apache.org > Subject: Re: Structured Lucene documents > > On 13/08/07, Pierre-Yves LANDRON <[EMAIL PROTECTED]> wrote: > > > > Hello !Thanks Pieter,That seems a good idea - if not an ideal one - even > > if it sort of an hack. I will try it as soon as possible and keep you > > informed.The hl.fl parameter doesn't have to be initialized, I think, so > > it won't be a problem.On the other hand, I will have the exact same > > problem to specify the (dynamic) field on wich the request is performed... I > > need to be able to execute the request on the full text of the page only : > > must I specify all of the -hightly variable- name of each page field in my > > query ?I think that structured index document could be of great value to > > complex documents indexation. Is there a way that someday Solr will include > > such possibility, or is it basically impossible (due to the way Lucene works > > for example) ?Kind Regards,Pierre-Yves Landron > > > Hi Pierre-Yves, > > Maybe you could use dynamic field copy in your schema.xml to index content > from all page stored in your document in a separate field, something like: > > <copyField source="page*" dest="all_pages" /> > > and then you would only need to query on the "all_pages" field. Not quite > sure how this might be affected by the hl.requireFieldMatch=true parameter > but it's worth a try. > > cheers, > Piete _________________________________________________________________ Invite your mail contacts to join your friends list with Windows Live Spaces. It's easy! http://spaces.live.com/spacesapi.aspx?wx_action=create&wx_url=/friends.aspx&mkt=en-us