graveyard v0.6.1 Graveyard.ORM.Query.Nested View Source

Link to this section Summary

Functions

Returns a Tirexs-ready keyword list structure for a nested query (reference: https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-nested-query.html) The format of filter must follow this example

%{"type" => "nested", "path" => "path_to-field", "queries":
  [
    %{"type" => "match", "field" => "name", "value" => "Jav"},
    %{"type" => "match", "field" => "iss", "value" => 23 }
  ]
}

For additional info on how to merge first-order queries and nested queries in a single Elastic query, see (https://stackoverflow.com/questions/15577474/combined-non-nested-and-nested-query-in-elasticsearch)

Link to this section Functions

Returns a Tirexs-ready keyword list structure for a nested query (reference: https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-nested-query.html) The format of filter must follow this example

%{"type" => "nested", "path" => "path_to-field", "queries":
  [
    %{"type" => "match", "field" => "name", "value" => "Jav"},
    %{"type" => "match", "field" => "iss", "value" => 23 }
  ]
}

For additional info on how to merge first-order queries and nested queries in a single Elastic query, see (https://stackoverflow.com/questions/15577474/combined-non-nested-and-nested-query-in-elasticsearch)