![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Remove Duplicate lines from File | Nysif Steve | UNIX for Dummies Questions & Answers | 18 | 09-09-2007 08:57 AM |
| how to remove duplicate lines | fredao | Shell Programming and Scripting | 3 | 12-13-2006 12:51 PM |
| Remove duplicate | sabercats | Shell Programming and Scripting | 2 | 03-31-2006 12:35 PM |
| remove duplicate files in a directory | asinha63 | Shell Programming and Scripting | 1 | 03-13-2006 03:46 PM |
| Remove Duplicate Lines in File | Teh Tiack Ein | Shell Programming and Scripting | 5 | 01-12-2006 08:30 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|||||
|
Hi
Having a file as follows Code:
================================================== Date Time error code server ====================================================== 12-29-08 10:10 121221 server A 12-29-08 10:12 121221 server A 12-29-08 10:10 121221 server B 12-29-08 10:10 121221 server B if date=12-29-08 and server=server A . Must delete the line with old time and keep the latest. Found similiar post in this forum but dont know how to use with my condition. anyone can suggest Thanks in advance |
|
||||
|
Additional Question of "sort -u filename"
Hi there,
I use the same command you suggested but I found out it also sort the order. What else command I can remove any duplicated line but without change the order of the file. Thank in advanced! QuynhDang ![]() |
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Tags |
| shell script, shell scripting, unix scripting, unix scripting basics |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|