跳到主要内容
跳到主要内容

ASCII

ascii

description

Syntax

INT ascii(VARCHAR str)

返回字符串第一个字符对应的 ascii 码

example

mysql> select ascii('1');
+------------+
| ascii('1') |
+------------+
| 49 |
+------------+

mysql> select ascii('234');
+--------------+
| ascii('234') |
+--------------+
| 50 |
+--------------+

keywords

ASCII