I have values in two columns separated by commas, like showm below
I need the Output Like
How to do this in SQL server ? Thank You in advance.
Thank You,
Aravindan
Technology Tips and News
I have values in two columns separated by commas, like showm below
I need the Output Like
How to do this in SQL server ? Thank You in advance.
Thank You,
Aravindan
Check out my article on splitters.
DECLARE @table TABLE (A NVARCHAR(20), B NVARCHAR(20)) INSERT INTO @table (A, B) VALUES ('1,2','a,b'),('3,4','x,y,z') SELECT a.value AS columnA, b.value AS columnB FROM @table CROSS APPLY dbo.splitter(A,',') a CROSS APPLY dbo.splitter(B,',') b
I have values in two columns separated by commas, like showm below
I need the Output Like
How to do this in SQL server ? Thank You in advance.
Thank You,
Aravindan