lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Gross <cogr...@gmail.com>
Subject Custom Solr Query Post Filter
Date Wed, 08 Oct 2014 17:17:31 GMT
Code:
http://pastebin.com/tNjzDbmy

Solr 4.9.0
Tomcat 7
Java 7

I took Erik Hatcher's example for creating a PostFilter and have modified
it so it would work with Solr 4.x.  Right now it works...the first time.
If I were to run this query it would work right:
http://localhost:8080/solr/plugintest/select?q=*:*&sort=uniqueId%20desc&fq={!classif%20creds=ABC}
However, if I ran this one:
http://localhost:8080/solr/plugintest/select?q=*:*&sort=uniqueId%20desc&fq={!classif%20creds=XYZ}
I would get the results from the first query.  I could do a different
query, like:
http://localhost:8080/solr/plugintest/select?q=uniqueId[* TO
*]&sort=uniqueId%20desc&fq={!classif%20creds=XYZ}
and I'd get the XYZ tagged items.  But if I tried to find ABC with that one:
http://localhost:8080/solr/plugintest/select?q=uniqueId[* TO
*]&sort=uniqueId%20desc&fq={!classif%20creds=ABC}
it would just list the XYZ items.

I'm not sure what is persisting where to cause this to happen.  Anybody
have some tips/pointers for building filters like this for Solr 4.x?

Thanks!

-- Chris

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message