Mmmm 2009/9/8 Yonik Seeley <yo...@lucidimagination.com>: > This should work, and there are unit tests. Make sure the server you > are talking to is a recent release of 1.4, and then get the full stack > trace from the solr server. >
I'm running the release with the following in the CHANGES.txt file. $Id: CHANGES.txt 812246 2009-09-07 18:28:16Z yonik $ The full exception from the response is: exception":"org.apache.solr.common.SolrException: undefined field {!ex=colour}material\n\tat org.apache.solr.schema.IndexSchema.getField(IndexSchema.java:994)\n\tat org.apache.solr.request.SimpleFacets.getTermCounts(SimpleFacets.java:152)\n\tat org.apache.solr.request.SimpleFacets.getFacetFieldCounts(SimpleFacets.java:182)\n\tat org.apache.solr.request.SimpleFacets.getFacetCounts(SimpleFacets.java:96)\n\tat org.apache.solr.handler.component.FacetComponent.process(FacetComponent.java:70)\n\tat org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:169)\n\tat org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:131)\n\tat org.apache.solr.core.SolrCore.execute(SolrCore.java:1204)\n\tat org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:303)\n\tat org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:232)\n\tat org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1089)\n\tat org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:365)\n\tat org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)\n\tat org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)\n\tat org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:712)\n\tat org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405)\n\tat org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:211)\n\tat org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)\n\tat org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:139)\n\tat org.mortbay.jetty.Server.handle(Server.java:285)\n\tat org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:502)\n\tat org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:821)\n\tat org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:513)\n\tat org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:208)\n\tat org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:378)\n\tat org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:226)\n\tat org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:442)\n"} I'm going to try with a brand new index build from scratch with a simple schema Thanks Gareth > -Yonik > http://www.lucidimagination.com > > > > On Tue, Sep 8, 2009 at 9:08 AM, gareth > rushgrove<gar...@morethanseven.net> wrote: >> Thanks for the quick replies guys. Afraid that didn't work. >> >> 2009/9/8 gwk <g...@eyefi.nl>: >>> >>> Try removing the space between de closing bracket } and the field name, I >>> think that should work. >>> >> >> I tried: >> >> http://172.16.142.130:8983/solr/products/select/?q=material:metal&fq={!tag=colour}colour:Red&start=24&rows=25&indent=on&wt=json&facet=on&facet.sort=false&facet.field=colour&facet.field={!ex=colour}material&sort=popularity%20desc >> >> I'd actually tried this first and added the space to see if that was >> needed, then missed it when I pasted in the URL from the browser. >> >> Looking at the docs I thought this would be the correct syntax, but I >> still get the same exception: >> >> "exception":"org.apache.solr.common.SolrException: undefined field >> {!ex=colour}material\n\tat >> >> Thanks >> >> Gareth >> >>> Regards, >>> >>> gwk >>> >>> >>> gareth rushgrove wrote: >>>> >>>> Hi All >>>> >>>> Hoping someone might be able to help me with a problem. >>>> >>>> I downloaded and got up and running with the latest nightly release of >>>> Solr: >>>> http://people.apache.org/builds/lucene/solr/nightly/solr-2009-09-08.zip >>>> >>>> In order to try out the tagging and excluding filters which have a >>>> note saying they are only available in 1.4. >>>> >>>> >>>> http://wiki.apache.org/solr/SimpleFacetParameters#head-4ba81c89b265c3b5992e3292718a0d100f7251ef >>>> >>>> I have a working index that I can query against, for instance the >>>> following returns what I would expect: >>>> >>>> >>>> http://172.16.142.130:8983/solr/products/select/?q=material:metal&fq={!tag=cl}colour:Red&start=24&rows=25&indent=on&wt=json&facet=on&facet.sort=false&facet.field=colour&facet.field=material&sort=popularity%20desc >>>> >>>> However, once I add the {!ex part it throws an exception: >>>> >>>> >>>> http://172.16.142.130:8983/solr/products/select/?q=material:metal&fq={!tag=colour}colour:Red&start=24&rows=25&indent=on&wt=json&facet=on&facet.sort=false&facet.field=colour&facet.field={!ex=colour}%20material&sort=popularity%20desc >>>> >>>> specifically "exception":"org.apache.solr.common.SolrException: >>>> undefined field {!ex=colour} material\n\tat >>>> >>>> The schema I'm using was copied from a working solr 1.3 install and as >>>> mentioned works great with 1.4, except for this issue I'm having >>>> >>>> So: >>>> >>>> * Do I have to enable this feature somewhere? >>>> * Is the feature working in the latest release? >>>> * Is my syntax correct? >>>> * Do you have to define the tag name somewhere other than in the query? >>>> >>>> Any help much appreciated. >>>> >>>> Thanks >>>> >>>> Gareth >>>> >>>> >>> >>> >> >> >> >> -- >> Gareth Rushgrove >> >> Web Geek >> Member WaSP Education Task Force >> >> morethanseven.net >> garethrushgrove.com >> > -- Gareth Rushgrove Web Geek Member WaSP Education Task Force morethanseven.net garethrushgrove.com