18 December 2013

CHARINDEX Function in sqlserver

The CHARINDEX string function returns the starting position of the specified expression in a character string.  It accepts three parameters with the third parameter being optional.


SELECT CHARINDEX('a', 'adinarayanareddy')

 

SELECT CHARINDEX('na', 'adinarayanareddy')

No comments:

Post a Comment