x

Data in certain fields in a table needs to be encrypted and later on decrypted to be used in sp. What should be the appropriate data type that can be used so that the same column can hold both the encrypted form and decrypted form of data?

The requirement is that the data in certain columns need to be encrypted after data is loaded and later on need to be decrypted so that these values can be used in calculations in a stored proc. My questions are :- Do I add new columns to the existing table to hold encrypted data in varbinary or something? What can be the appropriate data type that can hold both the encrypted value and the value after decryption in the same column?

more ▼

asked Apr 18, 2014 at 05:29 AM in Default

avatar image

sumitava20
1 1 2

Also please suggest how can I approach this problem of encryption ?? Do i move out these fields in separate tables? Will it help me in any way ?? I will be grateful if I can get some quick suggestions on this?

Apr 18, 2014 at 05:32 AM sumitava20

you may also wish to combine this question with your original question in the form of a comment.

Apr 21, 2014 at 07:14 AM nidheesh.r.pillai

please post this question in the default section and not the meta-askssc section.

Apr 21, 2014 at 07:13 AM nidheesh.r.pillai

Moved to Default section.

Apr 21, 2014 at 08:26 AM Dave_Green ♦
(comments are locked)
10|1200 characters needed characters left

1 answer: sort voted first

If you're going to encrypt individual columns (not something I've done personally), I've always seen it done as binary storage.

more ▼

answered Apr 22, 2014 at 10:05 AM

avatar image

Grant Fritchey ♦♦
137k 20 43 81

(comments are locked)
10|1200 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

SQL Server Central

Need long-form SQL discussion? SQLserverCentral.com is the place.

Topics:

x54
x37
x7

asked: Apr 18, 2014 at 05:29 AM

Seen: 458 times

Last Updated: Apr 22, 2014 at 10:05 AM

Copyright 2016 Redgate Software. Privacy Policy