THE WORLD'S LARGEST WEB DEVELOPER SITE

SQL Server CHAR() Function

❮ SQL Server Functions

Example

Return the character based on the number code 65:

SELECT CHAR(65) AS CodeToCharacter;
Try it Yourself »

Definition and Usage

The CHAR() function returns the character based on the ASCII code.

Syntax

CHAR(code)

Parameter Values

Parameter Description
code Required. The ASCII number code to return the character for

Technical Details

Works in: SQL Server (starting with 2008), Azure SQL Database, Azure SQL Data Warehouse, Parallel Data Warehouse

❮ SQL Server Functions