Splitting Comma separated values in columns to multiple rows in Sql Server -
There are three columns in my table, one of the columns [ this gives me the following results : , then in columns A new line is displayed according to each value and the other column should have duplicated data. I hope I am very clear from the problem. Col3 ] has multiple values, therefore, When I make a specific order on the table:
call 1 with my call, cola 2, select colle 3
Col1 Col2 Col3 ------------------------------ Line 1 430 A319 N1160 N1336 If there is a way to get the output:
Col1 Col2 Col3 -------- ---- ------------------ Line 1 430a 319 Columns such as N-1160 line 2 430A319N336 line 3 ABC FEG G3489 Row 4 ABCEFF M 5678 RO 5 ABC NFEF N 5643
select col1, col2, split.a.value ('.', 'Varchar ( 100) 'from 3 to (SELECT col1, col2, cast (' & lt; m & gt; '+ Change (col3,' ','
Comments
Post a Comment