Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.
byte bytes = new byte[file.ContentLength]; file.InputStream.Read(bytes, 0, file.ContentLength);
OPEN SYMMETRIC KEY MyTableKey DECRYPTION BY CERTIFICATE EncryptMyCert INSERT INTO dbo.DocumentFiles (LetterFileId, NameFile, ContentType, Doc, FileSizeBytes, UpdateUser, updateDate) SELECT @fileId, ENCRYPTBYKEY(KEY_GUID('ArmsTableKey'),@FileName), --- this works @ContentType, ENCRYPTBYKEY(KEY_GUID('ArmsTableKey'),@doc), -- this doesnt work -- @doc, --- this works @fileSizeBytes, @username, GETDATE() END
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.