Operating System - HP-UX
1834080 Members
2453 Online
110063 Solutions
New Discussion

How to merge the two files?

 
SOLVED
Go to solution
diwakar_4
Frequent Advisor

How to merge the two files?

Hi All,

I have two files like:

File1.txt contains:

"FirstName"
"Last Name"
"Company"
"Annuval salary"

File2.txt contains corresponding resords:
"Geff"
"Hogson"
"ABC Limited"
"2000 dollor"

I want out like:

output.txt

"FirstName","Geff"
"Last Name","Hogson"
"Company","ABC Limited"
"Annuval salary","2000 dollor"

Can some one please help how to dothis?

Thanks
5 REPLIES 5
Shrikant Lavhate
Esteemed Contributor

Re: How to merge the two files?

chk this thread

http://forums11.itrc.hp.com/service/forums/questionanswer.do?threadId=950968

Will it remain a personal, if I broadcast it here!
TTr
Honored Contributor

Re: How to merge the two files?

"man paste"
James R. Ferguson
Acclaimed Contributor
Solution

Re: How to merge the two files?

Hi:

# paste -d "," File1.txt File2.txt > output.txt

Regards!

...JRF...
diwakar_4
Frequent Advisor

Re: How to merge the two files?

Hi All,

Many thanks.

This is working for me.

Thanks
diwakar_4
Frequent Advisor

Re: How to merge the two files?

Closing the tread many thanks to all of you fro helping me.