[opencms-dev] *****POSSIBLE SPAM***** Re: SOLR Multi-field Settings

Michael Sperdin m.sperdin at inetservice.at
Tue Nov 13 23:25:56 CET 2012


hello 

i can show you how to use the multivalued fields

you habe to male ah little workround and define the field

id you're interested just send me an short mail with your problem

Von meinem iPhone gesendet

Am 13.11.2012 um 23:20 schrieb Rüdiger Kurz <r.kurz at alkacon.com>:

> Hi,
> 
> this is currently not possible out of the box, but it is already implemented in the current development branch and therefore it will be part of a future release. For now you can implement the interface org.opencms.search.fields.I_CmsSearchFieldMapping and than configure it inside the XSD schema of your resource type by adding something like:
> 
> <solrfield targetfield="Author">
> <mapping type="dynamic" class="org.opencms.yourClass">special</mapping>
> </solrfield>
> 
> have a look at org.opencms.search.solr.CmsDynamicDummyField
> 
> good luck!
> 
> regards
> Rüdiger
> 
> Am 13.11.2012 16:57, schrieb John James Valentine:
>> Does anyone have an example on how to use a multifield with solr and the
>> new search settings in an XML Content XSD file on OpenCms 8.5?
>> 
>> An example use case would be an author for a news story, there may be
>> multiple authors and we would want solr to index all the
>> 
>> authors for that XML content.
>> 
>> Here is the search settings from the XSD:
>> 
>> <searchsettings>
>> 
>> <searchsetting element="Author" searchcontent="true">
>> 
>> <solrfield targetfield="Author" sourcefield=”*_txt” copyfields=”*” />
>> 
>> </searchsetting>
>> 
>> </searchsettings>
>> 
>> The solr field Author_en_txt has been indexed:
>> 
>> <arr name="Author_en_txt">
>> 
>> <str>My Indexed Author</str>
>> 
>> </arr>
>> 
>> We would expect :
>> 
>> <arr name="Author_en_txt">
>> 
>> <str>My Indexed Author</str>
>> 
>> <str>Another Indexed Author</str>
>> 
>> </arr>
>> 
>> Thanks so much,
>> John Valentine
> 
> 
> -- 
> Kind Regards,
> Rüdiger.
> 
> -------------------
> 
> Rüdiger Kurz
> 
> Alkacon Software GmbH  - The OpenCms Experts
> http://www.alkacon.com - http://www.opencms.org
> _______________________________________________
> This mail is sent to you from the opencms-dev mailing list
> To change your list options, or to unsubscribe from the list, please visit
> http://lists.opencms.org/cgi-bin/mailman/listinfo/opencms-dev
> 
> 
> 
> 
> 
> Das Mail wurde von der Ikarus MyMailwall überprüft und enthält keinen Virus.


More information about the opencms-dev mailing list