Ajay Takur
Ajay Takur

Reputation: 6236

Elasticsearch 8.9 version error: [match] unknown token [START_ARRAY] after [query]

I am trying to get my Elasticsearh query to work, but I get this error:

org.elasticsearch.common.ParsingException: [match] unknown token [START_ARRAY] after [query]

This is my query:

{
    "size": 25,
    "from": 0,
    "sort": [
        {
            "r_date.keyword": {
                "order": "desc"
            }
        }
    ],
    "query": {
        "bool": {
            "must": [
                {
                    "match": {
                        "c_id": {
                            "query": ["TSM"]//it should accept multiple values
                        }
                    }
                },
                {
                    "match": {
                        "sec": {
                            "query": 
                                "500"
                            
                        }
                    }
                },
                {
                    "range": {
                        "r_date": {
                            "gte": "02/28/2023",
                            "lte": "08/29/2023",
                            "format": "MM/dd/yyyy"
                        }
                    }
                }
            ]
        }
    }
}

Upvotes: 0

Views: 87

Answers (0)

Related Questions