Hello Guru's,
EDIT: I do have an awk script that does most of the job for me. An equivalent to this awk script would be just fine.
awk '{t=$1;gsub(/"/,"",t);a[t]=a[t] FS $0} END {for (i in a) print a[i]}' filename
Making sure I post under the right category...windows powershell!
I have an awk script that does the job somewhat but I need a powershell script that transforms rows into columns.
Basically I need to join the rows into columns if the first column has the same value.
Below is the sample input file.
A 1,2,3
A 4,5,6
B 1,2,3
B 4,5,6
C 1,2,3
C 2,3,4
C 3,4,5
Here is the desired output:
A 1,2,3,4,5,6
B 1,2,3,4,5,6
C 1,2,3,2,3,4,3,4,5
Cheers for any help :-)
- Edited by Knowledge_is_King 4 hours 12 minutes ago more information