Special character searchable or not

Hello,

I am using elastic search APIs v1.4.4 and have an issue with the name "1% Bonus Group". I am using wildcard type in our query and there is no result at all with * 1% * or 1% query.

{
"query": {
"bool": {
"must": [
{
"wildcard": {
"contacts.group_name": "* 1% *"
}
}
],
"must_not": [ ],
"should": [ ]
}
},
"from": 0,
"size": 10,
"sort": [ ],
"facets": { }
}

But when we change to query_string type with 1% words, the result is showing, but not showing with * 1% * words

{
"query": {
"bool": {
"must": [
{
"query_string": {
"default_field": "contacts.group_name",
"query": "* 1% *"
}
}
],
"must_not": [ ],
"should": [ ]
}
},
"from": 0,
"size": 10,
"sort": [ ],
"facets": { }
}

It is our issue because we want use * < searching words > * in our query. Could you please advise how to be able to search 1% in both types: query_string and wildcard type?

Thanks,

Hi did you try to add a '' before the % ?

yes, we tried with \ like * 1% * for query_string or wildcard type and there is no result.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.