Collections:
Unicode String Literals in SQL Server Transact-SQL
What are Unicode string literals supported in SQL Server Transact-SQL?
✍: FYIcenter.com
Unicode string literals in Transact-SQL are sequences of characters enclosed
in single quotes and prefixed with (N) as N'...'.
String literals are used to provide values to string variables or table columns like NCHAR(40), NVARCHAR(40), etc.
Unicode string literals are also used in string operations in expressions and string arguments in functions.
Here are some simple rules on how to write string literals:
Here are some example on how to write string literals:
PRINT N'FYIcenter.com'; PRINT N'Murphy''s law'; DECLARE @var NCHAR(2); SET @var = N'友爱'; PRINT @var;
⇒ Unicode Character String Literals in SQL Server Transact-SQL
⇐ CHAR(n) - Truncating/Padding Strings in SQL Server Transact-SQL
2017-05-05, 2966🔥, 0💬
Popular Posts:
How To Create a Dynamic Cursor with the DYNAMIC Option in SQL Server Transact-SQL? If the underlying...
How To Insert New Line Characters into Strings in SQL Server Transact-SQL? If you want to break a st...
How To Round a Numeric Value To a Specific Precision in SQL Server Transact-SQL? Sometimes you need ...
What Privilege Is Needed for a User to Delete Rows from Tables in Another Schema in Oracle? For a us...
How To Change the Password for Your Own User Account in MySQL? If you want to change the password of...