LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 09-16-2009, 03:04 PM   #1
kishorerhce508
LQ Newbie
 
Registered: Oct 2008
Posts: 26

Rep: Reputation: 15
Thumbs up mixing two data files ...


HI to all, this is Kishore and I am using Red Hat 5.1

I want to mix 2 files with patch or some other command what ever it may be

is there any command to mix two files where file1 will be (pipe symbols)

|||
|||
|||

and file2 will be (mail address)

kishore@gmail.com
kishore@yahoo.com
kishore@in.com

and finally the out put must be (there pipe symbols and email id )

|||kishore@gmail.com
|||kishore@yahoo.com
|||kishore@in.com

Can any one help me in this.....
 
Old 09-16-2009, 03:05 PM   #2
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
You may try the paste command.
 
Old 09-17-2009, 04:16 PM   #3
kishorerhce508
LQ Newbie
 
Registered: Oct 2008
Posts: 26

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by colucix View Post
You may try the paste command.
Thanks for your help. Finally i got my solution i used awk command for

this and i fixed my issus..
 
Old 10-13-2009, 07:29 AM   #4
Mohammad.Khaleel
LQ Newbie
 
Registered: Oct 2009
Posts: 3

Rep: Reputation: 0
HI
The solution is by using command
pr -tm

for example if you have two files
just type this command
pr -tm file1 file2 | awk '{print $1$2}'
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Synchonizing data files and creating a NAS third data set Odyssey1942 Linux - Newbie 5 07-23-2009 06:44 AM
Merging Data Files toshibalaptoplinux Linux - Newbie 6 12-14-2008 11:32 PM
problem in mounting cdrom(audio files running but not reading data files) amit_usual Linux - Newbie 7 12-29-2007 05:52 AM
Shell programming: Question about source files and read data from the files ccwq Programming 3 08-05-2007 12:13 AM
processing data within files PirateJack Linux - Newbie 3 03-28-2006 10:32 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 04:38 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration