Bitwise expression functions

This family of functions can be used to perform bitwise operations on numbers or a group of numeric records.

Function NameSyntaxSummary Description
BITANDBITAND(a, b)Bitwise AND of two numeric or binary expressions (a and b).
BITAND_AGGBITAND_AGG(a)Bitwise AND value of all non-NULL numeric records in a group a.
BITNOTBITNOT(a)Bitwise negation of a numeric or binary expression.
BITORBITOR(a, b)Bitwise OR of two numeric or binary expressions (a and b).
BITOR_AGGBITOR_AGG(a)Bitwise OR value of all non-NULL numeric records in a group a.
BITSHIFTLEFTBITSHIFTLEFT(a, n)Shift the bits for a numeric or binary expression n positions to the left.
BITSHIFTRIGHTBITSHIFTRIGHT(a, n)Shift the bits for a numeric or binary expression n positions to the right, with sign extension.
BITXORBITXOR(a, b)Bitwise XOR of two numeric or binary expressions (a and b).
BITXOR_AGGBITXOR_AGG(a)Bitwise XOR value of all non-NULL numeric records in a group a.
GETBITGETBIT(a, n)Return the bit at position n in a numeric expression.