Jump to content
Sign in to follow this  
BenW

Canadian SIN

Recommended Posts

I have created a regex for Canadian SIN but I am getting false hits due to 0000 numbers.

 (\d{3}-\d{3}-\d{3})|(\d{3}\s\d{3}\s\d{3})

Share this post


Link to post
Share on other sites

Hi BenW,

According to this article http://id-check.artega.biz/info-ca.php, The first digit of a SIN indicates the province in which it was registered. Therefore any SIN number that starts with a zero would be fictitious. The regex that I provided earlier would ignore all SIN numbers that with a zero. That would also filter out a string zeros.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...