[thelist] Monday Munificence
Scott Dexter
sgd at ti3.com
Mon Mar 12 12:43:54 CST 2001
(how's that for alliteration?)
<tip type="SQL trickery">
Gotta table with Social Security Numbers (or Social Insurance Numbers in
Canada, I dunno about elsewhere), and need to make sure you prepend the
leading zero(s) when necessary?
try this (from MS SQL Server 7, though I think the functions are SQL
compliant):
Select REPLICATE('0', 9 - Len(t.SSN)) + t.SSN AS SSN from tbUsers
</tip>
sgd
--
work: http://www.ti3.com/
non: http://thinksafely.org/
More information about the thelist
mailing list