Sql server 2005, try this
--Lookup Table
DECLARE @Values TABLE(
Column_Name VARCHAR(MAX)
)
INSERT INTO @Values (Column_Name) SELECT 'A'
INSERT INTO @Values (Column_Name) SELECT 'B'
INSERT INTO @Values (Column_Name) SELECT 'ATADA'
INSERT INTO @Values (Column_Name) SELECT 'TADAA'
INSERT INTO @Values (Column_Name) SELECT 'Test123A'
INSERT INTO @Values (Column_Name) SELECT '1Test123A'
--Lookup string and delim
DECLARE @LookupString VARCHAR(MAX)
DECLARE @Delim VARCHAR(1)
SET @LookupString = 'Test1,Test2,TADA'
SET @Delim = ',';
--CREATE A LOOKUP TABLE FOR SPLIT STRINGS
WITH substrings (Val, Remainder) AS(
SELECT CASE WHEN CHARINDEX(@Delim,@LookupString) = 0 THEN @LookupString ELSE LEFT(@LookupString,CHARINDEX(@Delim,@LookupString)-1) END,
CASE WHEN CHARINDEX(@Delim,@LookupString) = 0 THEN '' ELSE RIGHT(@LookupString,LEN(@LookupString) - CHARINDEX(@Delim,@LookupString)) END
UNION ALL
SELECT CASE WHEN CHARINDEX(@Delim,Remainder) = 0 THEN Remainder ELSE LEFT(Remainder,CHARINDEX(@Delim,Remainder)-1) END,
CASE WHEN CHARINDEX(@Delim,Remainder) = 0 THEN '' ELSE RIGHT(Remainder,LEN(Remainder) - CHARINDEX(@Delim,Remainder)) END
FROM substrings
WHERE CHARINDEX(@Delim,Remainder) >= 0 AND Val != '' AND Remainder != ''
)
SELECT v.Column_Name,
substrings.Val
FROM @Values v INNER JOIN
substrings ON v.Column_Name LIKE substrings.Val + '%'