Search terms matching order of precedence?

Hi everyone, I would like to take a search query with multiple terms and
possibly define an order of precedence in the following way.

(bare with me as I become familiar with elasticsearch lingo!)

Can I specify that the exact match is first (The search words "word A word
B" matches "word A + word B"),
then it matches "word B + word A",
then just "word B" is found,
then either "word A or word B"

I'd like to understand how to shuffle the above variations as well?

Thanks much.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/405bb3f0-d496-4c3d-8aa8-ec7afaf2075f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Hello Eric ,

Please explore phrase query -

Also there is query_string type which has support for AND , OR etc and even
phrase query -

Hope that helps.

Thanks
Vineeth

On Fri, Aug 22, 2014 at 11:17 PM, Eric Greene ericdgreene@gmail.com wrote:

Hi everyone, I would like to take a search query with multiple terms and
possibly define an order of precedence in the following way.

(bare with me as I become familiar with elasticsearch lingo!)

Can I specify that the exact match is first (The search words "word A word
B" matches "word A + word B"),
then it matches "word B + word A",
then just "word B" is found,
then either "word A or word B"

I'd like to understand how to shuffle the above variations as well?

Thanks much.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/405bb3f0-d496-4c3d-8aa8-ec7afaf2075f%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/405bb3f0-d496-4c3d-8aa8-ec7afaf2075f%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAGdPd5mGsXg5q1u26aVRcXSn_sUom2R25koZ23HLvVOMEcQSbQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Hi Vineeth thanks so much this looks like it will help me.

I have another question, if you don't mind... (or should I post a new
question?)

I would like to specify my top results based on:

  1. A description field and tags both are hits.
  2. Description field only is a hit.
  3. Tags only have a hit.

Is there something I can learn about to understand this? Thanks Eric

On Friday, August 22, 2014 10:50:48 AM UTC-7, vineeth mohan wrote:

Hello Eric ,

Please explore phrase query -
Elasticsearch Platform — Find real-time answers at scale | Elastic

Also there is query_string type which has support for AND , OR etc and
even phrase query -
Elasticsearch Platform — Find real-time answers at scale | Elastic

Hope that helps.

Thanks
Vineeth

On Fri, Aug 22, 2014 at 11:17 PM, Eric Greene <ericd...@gmail.com
<javascript:>> wrote:

Hi everyone, I would like to take a search query with multiple terms and
possibly define an order of precedence in the following way.

(bare with me as I become familiar with elasticsearch lingo!)

Can I specify that the exact match is first (The search words "word A
word B" matches "word A + word B"),
then it matches "word B + word A",
then just "word B" is found,
then either "word A or word B"

I'd like to understand how to shuffle the above variations as well?

Thanks much.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearc...@googlegroups.com <javascript:>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/405bb3f0-d496-4c3d-8aa8-ec7afaf2075f%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/405bb3f0-d496-4c3d-8aa8-ec7afaf2075f%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/c3614746-8aa8-43d6-bda6-00787bc8abfa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Hello Eric ,

I don't exactly understand your requirement.
Please be elaborate.

Thanks
Vineeth

On Fri, Aug 22, 2014 at 11:37 PM, Eric Greene ericdgreene@gmail.com wrote:

Hi Vineeth thanks so much this looks like it will help me.

I have another question, if you don't mind... (or should I post a new
question?)

I would like to specify my top results based on:

  1. A description field and tags both are hits.
  2. Description field only is a hit.
  3. Tags only have a hit.

Is there something I can learn about to understand this? Thanks Eric

On Friday, August 22, 2014 10:50:48 AM UTC-7, vineeth mohan wrote:

Hello Eric ,

Please explore phrase query - http://www.elasticsearch.
org/guide/en/elasticsearch/reference/current/query-dsl-
match-query.html#_phrase

Also there is query_string type which has support for AND , OR etc and
even phrase query - Elasticsearch Platform — Find real-time answers at scale | Elastic
reference/current/query-dsl-query-string-query.html#query-
dsl-query-string-query

Hope that helps.

Thanks
Vineeth

On Fri, Aug 22, 2014 at 11:17 PM, Eric Greene ericd...@gmail.com wrote:

Hi everyone, I would like to take a search query with multiple terms and
possibly define an order of precedence in the following way.

(bare with me as I become familiar with elasticsearch lingo!)

Can I specify that the exact match is first (The search words "word A
word B" matches "word A + word B"),
then it matches "word B + word A",
then just "word B" is found,
then either "word A or word B"

I'd like to understand how to shuffle the above variations as well?

Thanks much.

--
You received this message because you are subscribed to the Google
Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to elasticsearc...@googlegroups.com.

To view this discussion on the web visit https://groups.google.com/d/
msgid/elasticsearch/405bb3f0-d496-4c3d-8aa8-ec7afaf2075f%
40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/405bb3f0-d496-4c3d-8aa8-ec7afaf2075f%40googlegroups.com?utm_medium=email&utm_source=footer
.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/elasticsearch/c3614746-8aa8-43d6-bda6-00787bc8abfa%40googlegroups.com
https://groups.google.com/d/msgid/elasticsearch/c3614746-8aa8-43d6-bda6-00787bc8abfa%40googlegroups.com?utm_medium=email&utm_source=footer
.

For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAGdPd5mTEe8pR45vfOqU0DFUCsY68o0Sx3-SCWNKdfWaft6Fvg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.