# Index and find emails using pre- and postfix wildcards

**URL:** <https://discuss.elastic.co/t/index-and-find-emails-using-pre-and-postfix-wildcards/22824>\
**Category:** Elasticsearch\
**Created:** [March 23, 2015, 2:09pm UTC](https://discuss.elastic.co/t/index-and-find-emails-using-pre-and-postfix-wildcards/22824 "2015-03-23T14:09:37Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Abid\_Hussain](https://avatars.discourse-cdn.com/v4/letter/a/dfb087/32.png) [@Abid\_Hussain](https://discuss.elastic.co/u/Abid_Hussain)\
**Post date:** [March 23, 2015, 2:09pm UTC](https://discuss.elastic.co/t/index-and-find-emails-using-pre-and-postfix-wildcards/22824/1 "2015-03-23T14:09:37Z")

</div>

Hi all,

I'm looking for an easy way to index documents containing an email field  
and searching for them using pre- and postfix wildcard queries (something  
similar to SQL: WHERE email LIKE '%search\_term%').

One way may be using the uax\_url\_email tokenizer but it seems that in this  
case prefix wildcards aren't supported. Is that true?

As an alternative I thought of using a not\_analyzed field to store the  
email adress and query them with a something like an ignorecase flag...?

Regards,

Abid

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/d1b4d2b3-d5f0-4177-8f84-27a9ae5e81b5%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/d1b4d2b3-d5f0-4177-8f84-27a9ae5e81b5%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 12:24am UTC](https://discuss.elastic.co/t/index-and-find-emails-using-pre-and-postfix-wildcards/22824/2 "2017-07-06T00:24:50Z")

</div>


