SQL Server/T-SQL Tutorial/String Functions/nchar function
Версия от 16:46, 26 мая 2010; (обсуждение)
Get Character Unicode Values
<source lang="sql">
3> 4> SELECT NCHAR(71), NCHAR(111), NCHAR(111), NCHAR(100), NCHAR(33) 5> GO - - - - - G o o d ! (1 rows affected) 1></source>
NCHAR Returns a Unicode character representing the number passed as a parameter.
<source lang="sql">
5> SELECT NCHAR(105) 6> 14> GO - i</source>
The NCHAR() function takes a positive integer between 0 and 65,535 and returns a datatype of nchar(1) with the corresponding Unicode character.
<source lang="sql">
Syntax for NCHAR(): NCHAR ( integer_expression ) 7> 8> SELECT NCHAR (252) 9> GO - ü (1 rows affected)</source>