![]() |
|
|
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 |
| to find header in Mp3 file and retrieve data | shashi | High Level Programming | 2 | 09-12-2008 04:03 AM |
| How to extract data from a huge file? | srsahu75 | Shell Programming and Scripting | 5 | 01-18-2008 05:06 AM |
| search and grab data from a huge file | ting123 | UNIX for Dummies Questions & Answers | 1 | 06-06-2006 10:41 PM |
| sed, insert data from a file to another? | ctcuser | Shell Programming and Scripting | 4 | 05-03-2005 02:43 PM |
| Insert a line as the first line into a very huge file | shriek | UNIX for Advanced & Expert Users | 3 | 03-09-2005 01:22 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
I have a file with data extracted, and need to insert a header with a constant string, say: H|PayerDataExtract
if i use sed, i have to redirect the output to a seperate file like sed ' sed commands' ExtractDataFile.dat > ExtractDataFileWithHeader.dat the same is true for awk and in its simplist form i could say echo 'H|PayerDataExtract' > ExtractDataFileWithHeader.dat cat ExtractDataFile.dat >> ExtractDataFileWithHeader.dat mv ExtractDataFileWithHeader.dat ExtractDataFile.dat but in all of the above an extra file is created. If i were to do this in vi manually the extra file could be avoided. Is there a way to avoid the extra file while still not having to manually use vi in a interactive manner? This is even more neccessary if the file uses over 50% filespace and an extra file will just double my usage , though temporarily |
| Bookmarks |
| Tags |
| non-interactive vi |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|