Categories: Binary
BIN
Returns the the binary representation of an expression.
Syntax
BIN(expression integer) → varchar
- expression: An integer expression to encode.
Examples
BIN exampleSELECT BIN(100)
-- 1100100
SELECT BIN(-100)
-- 11111111111111111111111110011100
SELECT BIN(null)
-- null