![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Advanced & Expert Users Expert-to-Expert. Learn advanced UNIX, UNIX commands, Linux, Operating Systems, System Administration, Programming, Shell, Shell Scripts, Solaris, Linux, HP-UX, AIX, OS X, BSD. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| compare files | spt | Shell Programming and Scripting | 1 | 05-09-2008 11:57 AM |
| Compare files | kharen11 | UNIX for Advanced & Expert Users | 25 | 03-14-2007 05:35 AM |
| Compare 2 files | agustincm | SUN Solaris | 2 | 10-17-2006 12:32 AM |
| Compare files across 2 UNIX boxes | flattyre | Shell Programming and Scripting | 2 | 09-27-2006 08:21 PM |
| Compare files | Berserk | Shell Programming and Scripting | 6 | 09-05-2005 05:04 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
UNIX; Compare two files
Hi Guys,
Requirement: Want to compare two files, if the the content of both files is same then show "Good result" else Show "Bad Result"[/B][/B] I am using the following logic if( cmp -s a b = 0 ) then echo "Good result" else echo "Bad result" exit 0 fi But this is not working. FYI, the content of file is as shown below Content of file a 0 TOTALS 8,325 17,887,904 13,907 163,243,465 1,306,821,707 10.9 % Of file b 0 TOTALS 8,325 10,000,904 13,907 163,243,465 1,306,821,707 10.9 % Since the 4th values in b is differnt so that output of If statement should be "Bad result" It will be really great if someone can help me out with this. Thanks, |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|