SQL Server 2016 introduces two new string functions namely STRING_SPLIT and STRING_ESCAPE.
This is Part 8 of 10 Part T-SQL Enhancements in SQL Server 2016 for Developers and DBAs. Click here to read it from the beginning….
STRING_SPLIT: This string function can be used to split the character expression using the specified separator.
For more information, see STRING_SPLIT (Transact-SQL).
Syntax: STRING_SPLIT (string , separator)
Example: SELECT STRING_SPLIT('MyTechMantra Helps DBAs and Developers Daily', ' ');
Output
MyTechMantra
Helps
DBAs
and
Developers
Daily
Trending SQL Server Articles and Tips
- SQL Server SIMPLE Recovery Model Step by Step Tutorial with Examples
- How to Identify CPU Bottlenecks in SQL Server Using Performance Counters
- FULL Database Backups in SQL Server Step by Step Tutorial with Examples
- How to Detect Virtual Log Files in SQL Server Transaction Log File
- Database Consistency Checker DBCC CHECK For Analysis Services Database in SQL Server 2016 for Tabular and Multidimensional Databases
STRING_ESCAPE: This function can escape special characters within texts and will return text with escaped characters. For more information, see STRING_ESCAPE (Transact-SQL).
Syntax: STRING_ESCAPE(text , type)
Clicking Next Page button to continue reading the topics and click on the Previous Page button to revisit the previous topic.
Related Topics
- FORMATMESSAGE Statement
- SERVERPROPERTY Function
- TRUNCATE TABLE WITH PARTITIONS
- DROP IF EXISTS
- ALTER TABLE WITH (ONLINE = ON | OFF)
- MAXDOP for DBCC CHECKDB, DBCC CHECKTABLE and DBCC CHECKFILEGROUP
- ALTER DATABASE SET AUTOGROW_SINGLE_FILE
- ALTER DATABASE SET AUTOGROW_ALL_FILES
- COMPRESS and DECOMPRESS Functions
- STRING_SPLIT and STRING_ESCAPE Functions