ASCII
ASCII returns the numerical value of an ASCII character.
Syntax
ASCII (expression)
Remarks
| • | If you pass a NULL string to this function, it returns 0. |
| • | If the string is empty, this function returns 0. |
| • | Any character outside the range 0 to 255 is returned as an error or ignored, depending on the implementation of RDBMS. |
| • | If expression is a string with more than one character, only the first character is considered. |
Example
SELECT ASCII ('a') AS lowercase_a,ASCII('A') AS uppercase_a