mercredi 11 avril 2018

SSN and 9 digit number screening currently catching to many variables

Here are the 2 regex's used. The first is for a SSN type number with separators and the second is a straight 9-digit number with checks for characters before and after.

Regex("\D{1}\d{3}\D{1}\d{2}\D{1}\d{4}\D{1}")

Regex("\D{1}\d{9}\D{1}")

The problem is we catch other entries that resemble those but we need to be specific enough these aren't caught.

Such as -

(xxxx) xxx-xx-xxxx

684072943 (and order number etc.)

FA300217F0090

Potential Match #1:--------------- nt: ex: 201[[71230 0821]] am ex: 201[[71230 0821]] am 26 JUNE 2012 ---------------Potential Match #2:--------------- am ex: 201[[71230 0821]] am 26 JUNE 2012 DTG (date time group)

"[[ 210v13:2012]],"

Any ideas?

Aucun commentaire:

Enregistrer un commentaire