Red Gate forums :: View topic - Binary Data
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Data Generator 1
SQL Data Generator 1 forum

Binary Data

Search in SQL Data Generator 1 forum
Post new topic   Reply to topic
Jump to:  
Author Message
rodmusser



Joined: 26 Jan 2011
Posts: 1

PostPosted: Wed Jan 26, 2011 8:02 pm    Post subject: Binary Data Reply with quote

We use encrypted columns to store sensitive data (e.g. SSN, birthdates, etc). These columns are defined as varbinary types. How can I generate binary data so that they are functionally correct? For example, all SSN need to be 9 digits.
Back to top
View user's profile Send private message
james.billings



Joined: 16 Jun 2010
Posts: 1121
Location: My desk.

PostPosted: Fri Jan 28, 2011 10:36 am    Post subject: Reply with quote

The Binary generator will generate random values between 0 and the max as defined for the column by default. So a varbinary(50) column would end up with data randomly between those minimum and maximum lengths.

You can set these figures manually, so for your SSN column, you could set both Min Length and Max Length to 9.

If you need the binary values to be generated in a specific way to emulate your encryption routines however, you'll probably need to write a custom generator. You'll find some examples in:

C:\Program Files (x86)\Red Gate\SQL Data Generator 1\UserExample\Generator

(omit the (x86) if you're on a 32-bit OS)

And also some information on our website here
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group