If you’ve ever needed to generate random data inside SQL
server then you probably know what a pain it can be, especially when you need
that data to be human readable cities, states, names, phone numbers, etc.
This CLR make the task quick, easy and performs very well!
The download contains the CLR DLL, install script, example script and also a
great deal of pre-generated word lists.
Please keep in mind that this CLR was designed for
development and test environments and is not at all intended for production use.
- On the SQL Server, unzip to C:\
- Run script: C:\CLR\DataRandomizer\Install and Test.sql
- Of course, you can change the location if you also alter the script.
Example SQL Script:
dbo.GetRandomNumberString(10) as GetRandomNumberString,
dbo.GetRandomFullAddress() as GetRandomFullAddress,
dbo.GetRandomStreetAddress() as GetRandomStreetAddress,
dbo.GetRandomPhoneNumber() as GetRandomPhoneNumber,
dbo.GetRandomNumberOfWords(2, 5) as GetRandomNumberOfWords,
dbo.GetRandomCompanyName() as GetRandomCompanyName
dbo.GetRandomWords(3) as GetRandomWords,
dbo.GetRandomCity() as GetRandomCity,
dbo.GetRandomStreetSuffix() as GetRandomStreetSuffix,
dbo.GetRandomWord() as GetRandomWord,
dbo.GetRandomStreetName() as GetRandomStreetName,
dbo.GetRandomNumberStringLengthBetween(3, 5) as GetRandomNumberStringLengthBetween
dbo.FlipCoin() as FlipCoin,
dbo.GetRandomDomainSuffix() as GetRandomDomainSuffix,
dbo.GetRandomStateName() as GetRandomStateName,
dbo.GetRandomEmailAddress() as GetRandomEmailAddress,
dbo.GetRandomNumber(10, 20) as GetRandomNumber,
dbo.GetRandomCounty() as GetRandomCounty