13

Validating the record count

view full story
linux-howto

http://www.unix.com – Hi , I am having a text file with several records., it has a header record and trailer record. The header record has the number of rows (records) found in the text file and time-stamp. The footer record has the total number of records ( along with the header and trailer., Suppose: wc -l abc.txt -> Returns 150 (inclusive of header and trailer record) #EOF -> Trailer record has count 148 . I want a script that validates this that exactly matches., since i have several text files in a folder and manually validating takes time. Please advice. (HowTos)