HI Guys,
I have input file A.txt
1 AAA
1 BBB
1 1SW
1 2SW
1 3SW
1 BBB
1 PPP
1 1SW
1 PPP
1 1WS
1 1AS
1 P1P
1 AAA
I want Output base on same name in column B and that name at column C
Output.txt
1 AAA AAA
1 BBB BBB
1 1SW BBB
1 2SW BBB
1 3SW BBB
1 BBB BBB
1 PPP PPP
1 1SW PPP
1 PPP PPP
1 1WS AAA
1 1AS AAA
1 P1P AAA
1 AAA AAA
Between Both AAA and AAA all column have AAA but in inner loop all Column have PPP Between PPP same as BBB.