I'm struggling with ES syntax right now. Is there a way to match
e.g. term A against field A and term B against field B in a simple
boolean query?
The gist below "works" as in "returns the appropriate entries" using
sense as the client (despite sense complaining about the duplicate
"must") - but it doesn't feel right and it's not DRY.
I'm struggling with ES syntax right now. Is there a way to match
e.g. term A against field A and term B against field B in a simple
boolean query?
The gist below "works" as in "returns the appropriate entries" using
sense as the client (despite sense complaining about the duplicate
"must") - but it doesn't feel right and it's not DRY.
On Tue, Jul 16, 2013 at 11:19 PM, Alexander Reelsen alr@spinscale.de wrote:
good if it works! In order to improve slightly you could make the must field
an array which contains your queries.
Uh, yeah, that's what I'd like to do -- but what does that look like?
I thought I understood JSON format but NOTHING I can come up
with results in anything but errors like
QueryParsingException[[resources] [match] query malformed, no field]
A working example would be extremely helpful (and a good thing to
add to the docs, I'd think).
I'm using ES 0.90.0, BTW, in case this is a known problem.
With Chrome, FireFox,.. you can take a look at the generated JSON.
Hope this helps
Thank you, yes -- seeing some generated queries shed light on
my issue (which wasn't actually json-format-related), though now
I apparently need to go back to the docs for a little more study
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.