December 4th, 2008
BIT_LENGTH (no. of bits)
Posted by
admin in
H. ANSI Numeric Scalar Functions
The BIT_LENGTH function returns the number of bits contained in the value of the argument.
Format: BIT_LENGTH(expression)
Example: SELECT BIT_LENGTH('ABC') FROM TABLEA;
Result:
> PostgreSQL, and Sybase support BIT_LENGTH.
> Access, DB2, MySQL, Oracle, and SQL Server don’t support BIT_LENGTH.
> Oracle uses LENGTHB.