How guys,
I'm having a problem to display data from a field that contains many names separated for a semicolon. My client wants a display with just names that match the search criteria, like the below sample:
Fields
Domain Names
---------------------------------------------------------
England Alice;Bob;Carl;David;Elton
What I need is, using the following Query:
select * from database where Names like 'a%'
get
England Alice;Carl;David
or even having
select * from database where Names like 'Da%'
get
England David
and also, using
select * from database where Names like '%'
get
England Alice;Bob;Carl;David;Elton
I'm working on MS-SQL 2012 and I have a StoredProcedure to get the selected rows but everytime I get the result like the above/last line: all names.
How can I hilite/display just the located string by the entried criteria?
Thank you very much for any help.