I want to sort the results according to a specific field AND THEN apply the limit filter.
A simple common example would be a SQL query like select name from users order by name limit 100
would have returned the sorted results limited by 100.
I tried the same in Elasticsearch. However, this is not happening. It first applies the limits AND THEN sorts which is giving me undesired results. Can anyone point me what I am doing wrong ? This is the query I am currently using.
{
"sort": [
"full_name"
],
"filter": {
"limit": {
"value": 100
}
}
}