![]() |
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 a line within a file | new2ss | UNIX for Dummies Questions & Answers | 3 | 11-23-2008 02:34 PM |
| sed remove last 10 characters of a line start from 3rd line | minifish | Shell Programming and Scripting | 7 | 03-26-2008 04:42 PM |
| Copy all the files with time stamp and remove header,trailer from file | ksrams | UNIX for Dummies Questions & Answers | 35 | 07-30-2007 02:15 PM |
| How to remove last line of the file | mani_um | Shell Programming and Scripting | 3 | 05-14-2007 08:35 AM |
| Remove every third line from a file | bistru | Shell Programming and Scripting | 4 | 01-31-2006 07:26 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Remove header(first line) and trailer(last line) in ANY given file
Hi,
I need some help in removing the header (first line) and the trailer (last line) in a give file... The data file actually comes in EBCDIC format and I converted it into ASCII.. Now I need to strip off the first line and the last line.. I think we can use sed to do something like this: sed -n -e '2,964p' InPutFile.dat > OutPutFile.dat Since I know the file has 965 rows, I could do this...But I would like to automate this script.. Thank you, Madhu |
|
||||
|
Thank you for the message. I was just wondering if we can do the same thing on EBCDIC data file which is fixed width. Can we remove the lines depending on the number of bytes in an EBCDIC file? Like remove 23 bytes in the beginning and 8 bytes at the end...
Thanks again, Madhu |
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|