Running Drupal 6.19, Apache Solr 6.x-1.2, Biblio 6.x-1.x and apachesolr_biblio-HEAD and I import fails with 'multiple values encountered for non multiValued field ss_biblio_keywords' (full error below). If we delete this record and rerun the index it will bomb out on another, similar record; one that has multiple keywords, which is most of our records. How can we adjust this to use biblio_keywords as a multivalued field?
SEVERE: org.apache.solr.common.SolrException: ERROR:
[39bd135343b1/node/633] multiple values encountered for non
multiValued field ss_biblio_keywords: [Anatomy, Comparative, Cetacea,
Mammals, Skull]
at org.apache.solr.update.DocumentBuilder.toDocument(DocumentBuilder.java:214)
at org.apache.solr.update.processor.RunUpdateProcessor.processAdd(RunUpdateProcessorFactory.java:60)
at org.apache.solr.handler.XMLLoader.processUpdate(XMLLoader.java:139)
at org.apache.solr.handler.XMLLoader.load(XMLLoader.java:69)
at org.apache.solr.handler.ContentStreamHandlerBase.handleRequestBody(ContentStreamHandlerBase.java:54)
at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:131)
at org.apache.solr.core.SolrCore.execute(SolrCore.java:1316)
at org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:338)
at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:241)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365)
at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)
at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211)
at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)
at org.mortbay.jetty.Server.handle(Server.java:285)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:502)
at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:835)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:641)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:208)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:378)
at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:226)
at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)
Comments
Comment #1
phil.cryer commentedMore details on this, if we go into Admin -> Biblio settings -> Solr index and uncheck 'biblio_keywords' we can index all 11,000 biblio records into Solr, but if we re-enable that field (which we need since it has all the keywords related to that record), we get the same error as above. So, it's definitely the keywords field as defined by the apachesolr biblio module. Where is that to multivalued false for keywords? Can we just change that to TRUE somewhere? Thanks.
Comment #2
davidheskettmobot commentedI've written some modifications to this module that add a feature allowing you to specify 'single' or 'multiple' for a field. Previously the code relied on 'Data type' being 'date' and making the field multiple, which is not very helpful when you want strings to be treated as multiple for Solr searching purposes. The changes also correct some other slight issues we were having, and is based on this version: "apachesolr_biblio.module,v 1.2 2009/11/07 04:02:13 davidlesieur."
A side note, handling of dates, looks like there could be quite a variety of things done here to handle the broad range of input you could have, such as (2000 - 2005, MDCCLXXIII., [1887-1924], 1902-1991., 1908., [1903], [1911?-). Not to mention years with months and partial dates. I think that needs to be explored further, however, it could get fairly involved and may not fit all cases.
I will try and check this into Drupals source control, in the meantime, find the module on our (BHL, Missouri Botanical Gardens, for CiteBank) source control here: http://code.google.com/p/bhl-bits/source/browse#svn/trunk/citebank/drupa...