or-query.asciidoc 641 B

1234567891011121314151617181920212223242526272829
  1. [[query-dsl-or-query]]
  2. == Or Query
  3. deprecated[2.0.0, Use the `bool` query instead]
  4. A query that matches documents using the `OR` boolean operator on other
  5. queries.
  6. [source,js]
  7. --------------------------------------------------
  8. {
  9. "filtered" : {
  10. "query" : {
  11. "term" : { "name.first" : "shay" }
  12. },
  13. "filter" : {
  14. "or" : [
  15. {
  16. "term" : { "name.second" : "banon" }
  17. },
  18. {
  19. "term" : { "name.nick" : "kimchy" }
  20. }
  21. ]
  22. }
  23. }
  24. }
  25. --------------------------------------------------