I am in need of a macro which will help me achieve convert a single column comma delimited values into multiple rows.
Input xls file example:
A B C D E F G
1 Text1 Text2 description goes here S,SK,12,D5,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
2 Text1 Text2 description goes here S,MY,4,D0,0,NA|S,SR,6,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
3 Text1 Text2 description goes here S,SK,83,D0,0,NA|S,PT,45,D2,200,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
Output required is:
A B C D E F G
1 Text1 Text2 description goes here S,SK,12,D5,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
2 Text1 Text2 description goes here S,MY,4,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
2 Text1 Text2 description goes here S,SR,6,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
3 Text1 Text2 description goes here S,SK,83,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
3 Text1 Text2 description goes here S,PT,45,D2,200,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
So basically if COL E has multiple "|" delimited values, it should split and create a new row and rest should be the same. Also, need to have the time diff between COL G and COL F for each row.
Input xls file example:
A B C D E F G
1 Text1 Text2 description goes here S,SK,12,D5,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
2 Text1 Text2 description goes here S,MY,4,D0,0,NA|S,SR,6,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
3 Text1 Text2 description goes here S,SK,83,D0,0,NA|S,PT,45,D2,200,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
Output required is:
A B C D E F G
1 Text1 Text2 description goes here S,SK,12,D5,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
2 Text1 Text2 description goes here S,MY,4,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
2 Text1 Text2 description goes here S,SR,6,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
3 Text1 Text2 description goes here S,SK,83,D0,0,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
3 Text1 Text2 description goes here S,PT,45,D2,200,NA 12/9/2013 8:08:25 AM 12/9/2013 10:32:50 AM
So basically if COL E has multiple "|" delimited values, it should split and create a new row and rest should be the same. Also, need to have the time diff between COL G and COL F for each row.