lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Hostetter <hossman_luc...@fucit.org>
Subject Re: Weird operator precedence with default operator AND
Date Fri, 12 Oct 2007 00:33:47 GMT
: This would be nice, but unfortunately I do not have direct access
: to the solr server in my application. I need to parse queries,
: filter out blacklisted facettes and then parse them on to solr
: using solrj.

that depends ... what do you mean by a blacklisted facet?

facet counts are controlled by seperate query params then the query string 
... are you talking about preventing people from including field 
specific queries in their query string? i'm guessing that you mean 
something like this is okay...

        solr title:bobby body:boy

...but this isn't...

	solr title:bobby body:boy secret_field:xyzyq

...is that the idea?

the easiest approach is to do your own simple pass over the query string, 
and escape any metacharacters in clauses you don't like ... they'll be 
treated as "terms" and either be ignored (if they are optional) or cause 
the query to not match anything (if they are required)...

        solr title:bobby body:boy secret_field\:xyzyq







-Hoss


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message