Reputation: 95
I've problem with parsing pipe "|" character in elasticsearch. When record have any special characters no result data. Below my query
{
"query": {
"bool": {
"must": [
{
"term": {
"username": "john|[email protected]"
}
}
],
"must_not": [],
"should": []
}
},
I tried use "tokenizer":"uax_url_email"
, but not working
Upvotes: 0
Views: 488
Reputation: 5040
try with query_string ,Its working .I have tested in my system with default standard analyzer Try to Use query_string . Its very powerful in partial search in ES ,check my answer link :-
:-
{
"query": {
"query_string": {
"fields" : ["username"] ,
"query": "john|[email protected]"
}
}
}
Upvotes: 1