Subject RE: [firebird-support] How do I translate this piece of SqlServer stored proc code ?
Author Helen Borrie
At 05:23 AM 10/03/2008, you wrote:
>Helen,
>
>> All of the binary arithmetic UDFs were ported into the 2.1 server as
>> internal functions, along with BIN_SHR and BIN_SHL, but there's still
>no
>> BIN_NOT. I have asked WHY_NOT. ;-)
>
>While an inconvenience, it is a small oversight.
>
>After all, for BIN_NOT you can always ... NOT( A BIN_AND B)
>
>Or am I missing something?

It's not a logical "NOT". BIN_NOT flips the argument to its mirror image:

e.g. BIN_NOT (00001111) returns 11110000

I think it's sometimes called BIN_REV as well.

./heLen