I need to get some data from a column.
For example I have data in a column like peter@msn.com. I want to get msn.com.
How I can I get that?
try this:
DECLARE @a VARCHAR(100) = 'peter@msn.com'
SELECT RIGHT(@a, LEN(@a) - CHARINDEX('@', @a))
SELECT SUBSTRING(Columnname,7,LEN(Columnname));