Hi all!
I've got a field in a SQL 2000 db that holds an integer value that is set from a VB front-end (a series of 11 checkboxes) so that the number is a binary representation of whether the boxes are checked or not.
For example 11111111111 = all checked and a value in the DB of 8191 (decimal value of the binary).
My problem is that I have to interogate this decimal value from a SQL Stored Procedure to find out if 1 particular option is set (which affects an update statement).
Turning it back into binary in VB would be easy (and then check the appropriate bit) but how do I do this from within SQL??
Any help would be appreciated
Clegg
I've got a field in a SQL 2000 db that holds an integer value that is set from a VB front-end (a series of 11 checkboxes) so that the number is a binary representation of whether the boxes are checked or not.
For example 11111111111 = all checked and a value in the DB of 8191 (decimal value of the binary).
My problem is that I have to interogate this decimal value from a SQL Stored Procedure to find out if 1 particular option is set (which affects an update statement).
Turning it back into binary in VB would be easy (and then check the appropriate bit) but how do I do this from within SQL??
Any help would be appreciated
Clegg