|
Posted by Plamen Ratchev on 05/01/07 21:10
The expressions in the bitwise operations are treated as binary numbers, and
one of the expressions can be a binary data type. So, you do not have to
convert your binary value, just use it directly. The results is of data type
integer and you can convert it back to binary. Try this:
SELECT CAST(0x88186000 ^ 2 AS binary(4)),
CAST(0x88186000 | 2 AS binary(4)),
CAST(0x88186000 & 2 AS binary(4))
HTH,
Plamen Ratchev
http://www.SQLStudio.com
Navigation:
[Reply to this message]
|