![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | 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 here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| tell me whats wrong with this | nadman123 | Shell Programming and Scripting | 1 | 04-14-2008 08:58 PM |
| tell me whats wrong in this? | nadman123 | Shell Programming and Scripting | 1 | 04-09-2008 10:11 PM |
| if [ -s $File ] ; Whats wrong in this ?? | varungupta | UNIX for Advanced & Expert Users | 5 | 08-20-2007 10:24 PM |
| Whats wrong with this script? | kayarsenal | Shell Programming and Scripting | 2 | 08-25-2006 06:58 AM |
| Whats wrong with the mv command | dsravan | Shell Programming and Scripting | 0 | 08-10-2006 12:30 PM |
|
|
Submit Tools | LinkBack | Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
whats wrong with this awk???
while read LINE;
do echo |awk -v LIN="${LINE}" '{print substr(LIN,1,7)","substr(LIN,8,5)" ,"substr(LIN,14,10)","substr(LIN,24,6)" ,"substr(LIN,30,8)}'; done < exp1.txt exp1.txt = 1234 grgrg 203902 ksdjh oehr weo why it doesn't work?? thanks. |
| Forum Sponsor | ||
|
|
|
#2
|
||||
|
||||
|
Could you post the output ?
I get the right thing: 1234 gr,grg 2 ,3902 ksdjh, oehr ,weo |
|
#3
|
|||
|
|||
|
I did a mistake
thanks for your reply |
|
#4
|
|||
|
|||
|
what removed is going on????????
while read LINE; do echo LINE |awk -v LIN="${LINE}" '{print substr(LIN,1,7)","substr(LIN,8,5)","substr(LIN,14,10)","substr(LIN,24,6)","substr(LIN,30,8)","substr (LIN,38,4)}'; done < prefinal.txt prefinal.txt: 1234 grgrg 203902 ksdjh oehr weo why it doesn't work???????? removed cygwin Last edited by Perderabo; 04-04-2006 at 06:32 AM. Reason: Remove profanity |
|
#5
|
||||
|
||||
|
Quote:
(1) No flames, shouting (all caps), sarcasm, bullying, profanity or arrogant posts. Please adhere to the rules. |
|
#6
|
|||
|
|||
|
I am sorry,I didn't know about it...
|
|||
| Google The UNIX and Linux Forums |