Search query to return docs based on conditions inside the doc

Hi
I have a usecase where the conditions for returning the document is
predefined in the doc. At query time these conditions are unknown. Is there
a way to evaluate this before returning the search results.

Eg: document with id b1 should be returned when type == shoes and temp >
80 while
document b2 should be returned when type == shoes and temp == 80 and age <
20

Is it possible to construct queries to return the docs that match the
predefined conditions?
Appreciate any suggestion

Thanks
Sheeba

--
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.
For more options, visit https://groups.google.com/groups/opt_out.

Hi Sheeba

Only by marking docs b1 and b2 with some other field, like a category or
something, eg when type==shoes and type==80, then return docs of category
'foo'. So you'd need to store category 'foo' in the doc

clint

On 17 May 2013 03:48, Sheeba George sheeba.george@gmail.com wrote:

Hi
I have a usecase where the conditions for returning the document is
predefined in the doc. At query time these conditions are unknown. Is there
a way to evaluate this before returning the search results.

Eg: document with id b1 should be returned when type == shoes and temp >
80 while
document b2 should be returned when type == shoes and temp == 80 and age <
20

Is it possible to construct queries to return the docs that match the
predefined conditions?
Appreciate any suggestion

Thanks
Sheeba

--
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.
For more options, visit https://groups.google.com/groups/opt_out.

--
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.
For more options, visit https://groups.google.com/groups/opt_out.