From: Demian K. <dem...@vi...> - 2012-10-11 15:26:54
|
I would definitely encourage the use of a dynamic field if you have a new enough version of VuFind and can get the functionality you need from one of the standard field types. I think callnumber-swf_str (if you only need one value per record) or callnumber-swf_str_mv (for multi-valued fields) should do the job for you. - Demian From: Oliver Goldschmidt [mailto:o.g...@tu...] Sent: Thursday, October 11, 2012 11:23 AM To: vuf...@li... Subject: Re: [VuFind-General] Adding queryfield to "callnumber" Hi Christian, I think, the only thing you missed, was adding the field callnumber-swf to the Solr index. You have to define the field in solr/biblio/conf/schema.xml first (unless you are using a dynamic field name). Just copy one other field from the schema, name it callnumber-swf and restart the Solr server. Hope that helps, best wishes Oliver Am 11.10.2012 17:11, schrieb Christian Dabrowski: Hi all, I'd like to add a queryfield to the callnumber-query. The value is at least in the imported MARC-Data in the field 852 Subfield 9. I added to marc_local.properties this: callnumber-swf: 8529 Then I added to IndexRecord.php this function to be able to call the callnumber where I need it: protected function getCallNumberSWF() { return isset($this->fields['callnumber-swf']) ? $this->fields['callnumber-swf'] : ''; } In the searchsepcs.yaml I added in the section Callnumber this queryfields: - callnumber-swf: - [onephrase, ~] Finally as I wanted to reindex I received the error that the field "callnumber-swf" could not be found. What did I do wrong? thanks in advance, Christian p.d.: as a programming newbie I hope it's not total scrap what I wrote here. Thanks for your patience! ------------------------------------------------------------------------------ Don't let slow site performance ruin your business. Deploy New Relic APM Deploy New Relic app performance management and know exactly what is happening inside your Ruby, Python, PHP, Java, and .NET app Try New Relic at no cost today and get our sweet Data Nerd shirt too! http://p.sf.net/sfu/newrelic-dev2dev _______________________________________________ VuFind-General mailing list VuF...@li...<mailto:VuF...@li...> https://lists.sourceforge.net/lists/listinfo/vufind-general -- Oliver Goldschmidt TU Hamburg-Harburg / Universitätsbibliothek / Digitale Dienste Denickestr. 22 21071 Hamburg - Harburg Tel. +49 (0)40 / 428 78 - 32 91 eMail o.g...@tu...<mailto:o.g...@tu...> -- GPG/PGP-Schlüssel: http://www.tub.tu-harburg.de/keys/Oliver_Marahrens_pub.asc -- Projekt DISCUS http://discus.tu-harburg.de Projekt TUBdok http://doku.b.tu-harburg.de |