Skip to content
Snippets Groups Projects
Commit 254dfa1d authored by Aivaras Gotovskis's avatar Aivaras Gotovskis
Browse files

Add ids filter doc.

parent b4d0df10
No related branches found
No related tags found
No related merge requests found
# Ids Filter
> More info about ids filter is in the [official elasticsearch docs][1]
Filters documents that only have the provided ids.
## Simple example
```JSON
{
"ids" : {
"type" : "my_type",
"values" : ["1", "4", "100"]
}
}
```
And now the query via DSL:
```php
$idsFilters = new IdsFilter(
['1', '4', '100'],
['type' => 'my_type']
);
$search = new Search();
$search->addFilter($idsFilters);
$queryArray = $search->toArray();
```
[1]: https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-ids-filter.html
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment