• Jeff Moden - Tuesday, March 12, 2019 12:00 PM

    glenn.rollins3 - Tuesday, March 12, 2019 11:36 AM

    Jeff Moden - Tuesday, March 12, 2019 11:11 AM

    Sean Lange - Tuesday, March 12, 2019 8:33 AM

    glenn.rollins3 - Tuesday, March 12, 2019 8:02 AM

    I've been using the following and it's proved successful.

    WHERE LEN(SSN) <> 9
     OR LEFT(SSN,1) IN ('8')
     OR LEFT(SSN,2) IN ('74','78','79')
     OR LEFT(SSN,3) IN ('666','734','735','736','737','738','739','773','774','775','776','777','778','779')
     OR LEFT(SSN,3) = '000'
     OR SUBSTRING(SSN,4,2) = '00'
     OR SUBSTRING(SSN,6,4) = '0000'
     --OR SSN IS NULL
     OR SSN LIKE '%[a-z]%'

    Thoughts?

    I think that storing SSN in plain text is criminal behavior.

    Preach it, Brother!!!  Storing any form of Tax ID in an unencrypted fashion is just flat out wrong and a violation of every PII rule I've ever come across.

    Thanks, I'll pass it on to the company's IT department.

    No...  That's almost useless.  Pass it on to the CEO, the head of Marketing (while explaining the black eye to the company and resulting future lost business if there's a breach), the head of Finance (how much the breach will actually cost, which is more than you can currently imagine), AND the Director of IT (explain how they might not ever be able to find another job in IT if a breach occurs).  If the company is public, pass all that bad news on to the Board of Directors, as well.  The rank stupidity of things like clear text SSNs has got to stop.

    How do you really feel about this Jeff? It is hard to be sure. LOL. I agree on all points!!!

    _______________________________________________________________

    Need help? Help us help you.

    Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

    Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.

    Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
    Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
    Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
    Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/