469,923 Members | 1,563 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,923 developers. It's quick & easy.

Calling Encrypt2 function from Sqlserver select query

I use a database that has user names stored in Encrypted format using
the following API.

Declare Sub Encrypt2 Lib "QPRO32.DLL" (ByVal Work As String, ByVal
PASSWORD As String)

Every time i require the user name i have to again decrypt the name
using the same function.

My problem is that when i fetch a large number of records i have to
loop through every record and call the encrypt function for each
record.Instead of binding the recordset to my control i need to loop
through and fill my control
A MSHFlexGrid in Vb6.0.

Is there a way out to this problem that will make my record populatiog
faster withoutout changing the current Encrypted users.

Thanx in Advance
Jul 23 '05 #1
2 3166

"Udit Handa" <ud********@hotmail.com> wrote in message
news:82*************************@posting.google.co m...
I use a database that has user names stored in Encrypted format using
the following API.

Declare Sub Encrypt2 Lib "QPRO32.DLL" (ByVal Work As String, ByVal
PASSWORD As String)

Every time i require the user name i have to again decrypt the name
using the same function.

My problem is that when i fetch a large number of records i have to
loop through every record and call the encrypt function for each
record.Instead of binding the recordset to my control i need to loop
through and fill my control
A MSHFlexGrid in Vb6.0.

Is there a way out to this problem that will make my record populatiog
faster withoutout changing the current Encrypted users.

Thanx in Advance


From a server perspective, you could consider writing an extended stored
procedure to decrypt more than one user name and return them all in a result
set. (Or wait for MSSQL 2005 and write a stored proc using the .NET CLR to
do the same thing.) Although then you'd probably want to encrypt the network
traffic to the client, to prevent the unencrpyted user names going over the
network. If that doesn't help, I suspect you'll get better suggestions in a
VB or client-side forum as to how to process your grid most efficiently.

Simon
Jul 23 '05 #2
Depends on your reasons for using encryption. Assuming your database is
in a physically secure location then network protocol encryption will
be adequate for many applications. For the rest there are third party
applications and you can Google for those.

--
David Portas
SQL Server MVP
--

Jul 23 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by tango | last post: by
1 post views Thread by Darsin | last post: by
4 posts views Thread by raghuvendra | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.