Hi,
im looking for the right query to find in multiple fields a wildcard query (phone number in phone number fields).
i use
I try the Multi-match query with a part of given value, that returns 0 results.
The query as filter with wildcard with complete number (123456789)
=> returns 8 records
object(ONGR\ElasticsearchDSL\Query\Compound\BoolQuery)#1663 (2) {
["container":"ONGR\ElasticsearchDSL\Query\Compound\BoolQuery":private]=>
array(1) {
["must"]=>
array(1) {
["090632fe877364ef496234f6fc15d3f810b1f6e7a8ee71603345654778ec"]=>
object(ONGR\ElasticsearchDSL\Query\FullText\MultiMatchQuery)#1657 (3) {
["fields":"ONGR\ElasticsearchDSL\Query\FullText\MultiMatchQuery":private]=>
array(4) {
[0]=>
string(29) "data.detail.clientPhoneNumber"
[1]=>
string(32) "data.detail.mpServicePhoneNumber"
[2]=>
string(18) "data.detail.msisdn"
[3]=>
string(24) "data.detail.securecaller"
}
["query":"ONGR\ElasticsearchDSL\Query\FullText\MultiMatchQuery":private]=>
string(12) "*123456789*"
["parameters":"ONGR\ElasticsearchDSL\Query\FullText\MultiMatchQuery":private]=>
array(0) {
}
}
}
}
["parameters":"ONGR\ElasticsearchDSL\Query\Compound\BoolQuery":private]=>
array(0) {
}
}
=> result 8 records
The query as filter with wildcard with INcomplete number (3456789)
=> returns 0 records
...
["query":"ONGR\ElasticsearchDSL\Query\FullText\MultiMatchQuery":private]=>
string(12) "*3456789*"
...
Seems the multimatch query
is not the right one. Maybe i misunderstand the purpose of this query.
So, anyone can help me out?