Returns the platform-independent integer equivalent of a hexadecimal string.
hextoint(hexadecimal_string)
select hextoint ("0x00000100")
Use the hextoint function for platform-independent conversions of hexadecimal data to integers. hextoint accepts a valid hexadecimal string, with or without a “0x” prefix, enclosed in quotes, or the name of a character-type column or variable.
hextoint returns the integer equivalent of the hexadecimal string. The function always returns the same integer equivalent for a given hexadecimal string, regardless of the platform on which it is executed.
See the Transact-SQL Guide for more information about datatype conversion.
ANSI SQL – Compliance level: Transact-SQL extension.
Any user can execute hextoint.