Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Removing duplicate lines 2

Status
Not open for further replies.

ianicr

IS-IT--Management
Nov 4, 2003
230
GB
I have a file that has name/address/phone number data in eg.
Mr,T,Smith,1 New Street,01159845671
Mr,T,Smith,1 New Street,01159872345

I need to remove these duplicates but cannot use sort |uniq because they are not exactly the same. Is there a way to just check the first 4 fields and remove one of the lines?

 
Cheers. I did check this out but I thought it would only print the fields in the key. Oh well my mistake. Thanks mate
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top