ASCII returns the decimal representation of the character supplied in the 1st argument.

If your database is set to ASCII, then this will be the ASCII code for the character.

If your database is set to EBCDIC then it will be the EBCDIC code.

The argument can be a CHAR, VARCHAR2, NCHAR or NVARCHAR2 datatype.


SELECT ASCII(‘Z’) from dual;


Ascii – Oracle SQL Function
Tagged on: