Skip to main content

All Questions

Filter by
Sorted by
Tagged with
0 votes
2 answers
2k views

Converting multiple comma-separated columns into rows

I have an SQL Server database table that holds comma separated values in many columns. For example: id Column B column c 1 a,b,c, 1,2,3, 2 d, ,f, 4,5,6, 3 g,h,i,j, 7, ,9,8, I want to split all ...
jawad riaz's user avatar
8 votes
2 answers
2k views

Fastest way to split/store a long string for charindex function

I have a 1 TB string of digits. Given a 12-character sequence of digits I want to get the start-position of this sequence in the original string (charindex function). I have tested this with a 1GB ...
Werner Aumayr's user avatar
6 votes
1 answer
4k views

How to split XML array into separate rows (while upholding consistency)

I am working on the database dump of this exact stack exchange section. While I am working on it I have encountered one issue that I am currently unable to solve. In the XML File Posts.xml the ...
Chessbrain's user avatar
  • 1,223