Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- "_source": [
- "identifier",
- "document_type"
- ],
- "aggs":{
- "myaggs":{
- "terms":{
- "script":{
- "source":"doc['values.colors-reference_data_options.<all_channels>.<all_locales>']"
- }
- }
- }
- },
- "query": {
- "constant_score": {
- "filter": {
- "bool": {
- "filter": [
- {
- "exists": {
- "field": "values.colors-reference_data_options.<all_channels>.<all_locales>"
- }
- },
- {
- "script": {
- "script": {
- "source": "doc['values.colors-reference_data_options.<all_channels>.<all_locales>'].contains('redchilli')",
- "lang": "painless"
- }
- }
- }
- ]
- }
- }
- }
- },
- "size": 100,
- "sort": {
- "_uid": "asc"
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment