Using “Bitwise operators” we can perform bit manipulations between two integer data type category expressions.
- AND “&”
- OR “|”
- EXCLUSIVE OR “^”
AND: It
Performs a “Logical AND” operation between two integer values.
Example: SELECT 170&75
Result: 10
OR: It
performs a “Logical OR” operation between tow integer values.
Example: SELECT 170|75
Result: 235
Exclusive OR: It performs an “Exclusive OR” operation between tow integer values.
Example: SELECT 170^75
Result: 225
No comments:
Post a Comment