Multi match creates invalid query
See original GitHub issueThis example:
bodybuilder()
.query('multi_match', [ "info.name^3", "info.main_url^2" ], 'this is a test')
.filter('term', 'user', 'kimchy')
.build()
creates this query json:
{
"query": {
"bool": {
"filter": {
"term": {
"user": "kimchy"
}
},
"must": {
"multi_match": {
"info.name^3,info.main_url^2": "this is a test"
}
}
}
}
}
which is invalid query (tested with ES validate method ). I think problem is that multi_match expect ‘fields’ and ‘query’ argument and here it just creates query that is similar to normal match query.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:5
Top Results From Across the Web
Elastic Search multi match gets wrong result - Stack Overflow
The result from the Elastic using this query is a segment which includes "first_name" field "tony" and "last_name" field "lopez", but also a ......
Read more >Invalid Results with whitespace analyzer and Multi match search
We tried PUTTING custom analyzer and then re indexed all our indices. Now it works without specifying the analyzer while querying. But is...
Read more >Filter and pattern syntax - Amazon CloudWatch Logs
You can use pattern matching to create filter patterns that return log events containing single and multiple terms. Place a question mark ("?...
Read more >Multi-Match Detailed Results – Thursday, December 1, 2022
If you have a winning ticket, click here to schedule an appointment. Multi-Match Detailed Results. Thursday, December 1, 2022. 19-27-31- ...
Read more >Error messages | BigQuery - Google Cloud
Error table · Try breaking up the query into smaller pieces. · Try removing an ORDER BY clause. · If your query uses...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The idea with bodybuilder v2 is that for complex queries like multi_match or query_string, you only specify an options object, like this:
Just ran into this - would be great to have this documented in the docs somewhere!