Hey guys. To search for documents that have an exact value in a certain
field, is a query_string query the appropriate solution?
For example, after indexing this document:
{ name : "Super Grimlock", properties : { class: "Deluxe" } }
I can find it like this:
curl 'localhost:9200/test/products/_search' -d '
{ query: { query_string: { fields: ["name"], query: "Super Grimlock"
} } }'
Are there any other ways to perform this search? I've tried term queries
and term filters, but I assume they didn't work because terms aren't
analyzed.
Hey guys. To search for documents that have an exact value in a certain field, is a query_string query the appropriate solution?
For example, after indexing this document:
{ name : "Super Grimlock", properties : { class: "Deluxe" } }
I can find it like this:
curl 'localhost:9200/test/products/_search' -d '
{ query: { query_string: { fields: ["name"], query: "Super Grimlock" } } }'
Are there any other ways to perform this search? I've tried term queries and term filters, but I assume they didn't work because terms aren't analyzed.
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.