Query for email address within a text field

Hello,

I'm trying to query my index that contains text field with an email address. As of now, if query for a specific domain (eg gmail), like below and it gives me the results:

GET index*/_search
{
  "query": {
    "wildcard": {
      "sender": {
        "value": "*gmail.com*"
      }
    }
  }
}

But when i try to query for any email address, the there are 0 results:

GET index*/_search
{
  "query": {
    "wildcard": {
      "sender": {
        "value": "*@*"
      }
    }
  }
}

How could i make it work?

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