This project is read-only.

exclude terms in the query

Oct 14, 2008 at 5:56 PM
I don't see a way to exclude a term using solrsearch classes.

Let's say I want to search for "cars" but exclude audi keyword, I would run something like this on solr: cars !audi

If I pass that to QueryBuilder it escapes the ! character and passes audi to solr.

Is there a way to do excludes?
Dec 4, 2008 at 3:20 PM
Have you tried a query like:

q=(cars)NOT(audi)
?
Jan 2, 2009 at 6:16 PM
Actually what I did when using SolrQueryBuilder is use it like this: builder.AddFied("!fieldName", value)

And it worked.