In a column named "server_url" there are links :
After .com there is always a "/" present.
I want to get only the domain name as the output : www.abc.com , www.abcd.com
Have to remove the http:// from the start and whatever is there after the third "\".
Tried :
SUBSTRING( server_url, (charindex(':',server_url)+3), (charindex('/',server_url,10)))
I get the http removed. But its not removing the part after third '/'.
Please suggest a function to do the same.