If your call numbers all have colons in them, they may get interpreted as fielded Solr searches.  That might be part of your problem (see http://vufind.org/jira/browse/VUFIND-601 for a similar problem and proposed solution… though I haven’t had time to review this myself yet).

 

You might want to try turning on debug to see exactly what kind of queries are getting generated.

 

- Demian

 

From: Christian Dabrowski [mailto:dabrowski.christian@fh-swf.de]
Sent: Thursday, October 11, 2012 11:49 AM
To: vufind-general@lists.sourceforge.net
Subject: Re: [VuFind-General] Adding queryfield to "callnumber"

 

Hi Oliver and Demian,


thanks - it helped, at least half way:

I added the value in the schema.xml file and then I could reindex:   
<field name="callnumber-swf" type="string" indexed="true" stored="true" multiValued="true"/>

But when I perform a search I get no results - not if I search for an exact callnumber that I copied out of the catalogue (eg. Uck1 122:15A) nor the beginning part of it (eg. uck). I tried to change the values in the searchspecs and varied between  [append, "* "]   and [callnumber_exact, 1000] with [callnumber_fuzzy, ~] and  [onephrase, ~]. none of it worked.

Firebug shows me also this error: "NetworkError: 500 Internal Server Error - http://194.94.3.187/vufind/AJAX/JSON_Vis?method=getVisData&facetFields=publishDate&lookfor=uck&type=CallNumber&view=list&_=1349969871062"

Does anyone has a hint?

Christian

Am 11.10.2012 17:26, schrieb Demian Katz:

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.goldschmidt@tu-harburg.de]
Sent: Thursday, October 11, 2012 11:23 AM
To: vufind-general@lists.sourceforge.net
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
VuFind-General@lists.sourceforge.net
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.goldschmidt@tu-harburg.de
--
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




------------------------------------------------------------------------------
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
VuFind-General@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vufind-general