Answer: By deleting a specified number of characters from 1st string expression and replacing them with 2nd string expression, a string will be formed.
This SQL Stuff() function is used to return the newly formed string.
Important note is that, for deletion purpose, you have to specify the starting position and the length of the string.
Example:
SELECT STUFF('1234567',2, 3, '999');
It will display the result as: 1999567
Asked In: Many Interviews |
Alert Moderator