More computing sins are committed in the name of efficiency (without necessarily achieving it) than for any other single reason - including blind stupidity.
And using this command - nawk '!x[$1,$3]++' FS="|" tt
But it's just cleaning up the 3rd line !!! I just picked up the command from somewhere so not sure what needs to be changed. Help is appreciated :)
I am being sponsored by Syntress! They bought me an amazing dedicated server to run catonmat on. If you're looking web services, I highly recommend the Syntress guys!
Education Sponsors
I am being sponsored by A-Writer! If you ever need help with essay writing, look no further than A-Writer! They will help you with your writing in as quickly as 3 hours!
I have this file (using Sun OS) and need to delete rows if fields 1 and 3 are repeated
$ cat tt
yy|red|12|500|55
rr|red|12|500|55
yy|yellow|12|600|55
rr|yellow|13|600|55
Expecting output to be
rr|red|12|500|55
rr|yellow|13|600|55
And using this command - nawk '!x[$1,$3]++' FS="|" tt
But it's just cleaning up the 3rd line !!! I just picked up the command from somewhere so not sure what needs to be changed. Help is appreciated :)
Reply To This Comment