You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Furkan KAMACI <fu...@gmail.com> on 2017/06/22 20:54:21 UTC

SSN Regex Search

Hi,

How can I search for SSN regex pattern which overwhelms special dash
character issue?

As you know that /[0-9]{3}-[0-9]{2}-[0-9]{4}/ will not work as intended.

Kind Regards,
Furkan KAMACI

Re: SSN Regex Search

Posted by Erick Erickson <er...@gmail.com>.
First I wouldn't use regex queries, they're expensive.
WordDelimiter(Graph)Filter is designed for these use cases, have you
considered that?

And what do you mean: "special dash character issue"? Yes, it's the NOT
operator, but you can always escape it.

Best,
Erick

On Thu, Jun 22, 2017 at 1:54 PM, Furkan KAMACI <fu...@gmail.com>
wrote:

> Hi,
>
> How can I search for SSN regex pattern which overwhelms special dash
> character issue?
>
> As you know that /[0-9]{3}-[0-9]{2}-[0-9]{4}/ will not work as intended.
>
> Kind Regards,
> Furkan KAMACI
>