The BIT_AND function performs the bitwise logical AND operation on values in RAW r1 and RAW r2 and returns the result RAW of the AND operation.
Applicability
This topic applies only to OceanBase Database Enterprise Edition. OceanBase Database Community Edition provides only the MySQL mode.
Syntax
UTL_RAW.BIT_AND (
r1 IN RAW,
r2 IN RAW)
RETURN RAW;
Parameters
| Parameter | Description |
|---|---|
| r1 | The RAW value for performing the AND operation with r2. |
| r2 | The RAW value for performing the AND operation with r1. |
Return values
| Return value | Description |
|---|---|
| RAW | This value contains the result of the AND operation between r1 and r2. |
Considerations
If r1 and r2 are different in length, the AND operation ends at the last byte of the shorter RAW, and appends the unprocessed part of the longer RAW to the partial result. The length of the result is equal to that of the longer input RAW.