Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
awk program
Name: ssonu Date: August 27, 2007 at 10:26:12 Pacific OS: OS/2 CPU/Ram: p4
Comment:
Hi I'm a begginer to awk. I need to know how to compare 2 files with similar data, just that file 1 holds few records as when file 2 holds many records.
File 1:
Arnold Kim Mike Parris Kris Shay
File 2:
Arnold Kim Kevin Parker Mike Parris Ben Scott Kris Shay
If the records match in these two files I wanna generate an output file (file 3, with the matched records) Arnold Kim Mike Parris Kris Shay
James Booth shows you how to read a file into an awk array.
0
Response Number 2
Name: ghostdog Date: August 27, 2007 at 23:20:04 Pacific
Reply:
Since you are a beginner, you should be reading up on awk, trying to do it yourself first before even posting in any forums. however, giving you the benefit of doubt, here's one way in awk.
Summary: Hi, I am getting a syntax error in my awk program near else if statement. Can anyone suggest whats this error? is else if statement used correctly here? let me know if anyone has better logic to imple...
Summary: Hello everybody, I am trying to awk a file with multiple columns but I want to pickup from lines 3 to 80 the 3 first columns, and from lines 82 to 130 the column $2, and printf into a formated file...