i am trying to get records the has in \'title\' more then X characters.
NOTE: not all records contains title field.
i have tried:
GET books/_
You need to take into account that some documents might have a null title field. So you can use the groovy null-safe operator. Also make sure to use the POST method instead:
title
POST books/_search { "filter" : { "script" : { "script" : "_source.title?.size() > 10" } } }