On 2/12/2014 3:32 PM, Shamik Bandopadhyay wrote:
Hi,
I'm facing a weird problem while using q.op=AND condition. Looks like it
gets into some conflict if I use multiple "appends" condition in
conjunction. It works as long as I've one filtering condition in appends.
<lst name="appends">
<str name="fq">Source:"TestHelp"</str>
</lst>
Now, the moment I add an additional parameter, search stops returning any
result.
<lst name="appends">
<str name="fq">Source:"TestHelp" | Source:"TestHelp2"</str>
</lst>
If I remove "q.op=AND" from request handler, I get results back. Data is
present for both the Source I'm using, so it's not a filtering issue. Even
a blank query fails to return data.
I'm pretty sure that's not valid Solr query syntax for what you're
trying to do. Try this instead, although with these specific examples I
would leave the quotes out of the fq value:
<lst name="appends">
<str name="fq">Source:("TestHelp" OR "TestHelp2")</str>
</lst>
It's pretty much accidental (a result of the query analysis chain) that
it was working when you didn't have q.op=AND. You can verify what I'm
saying by looking at the parsed query when adding debugQuery=true as a
query option.
Thanks,
Shawn