![]() |
|
|
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 |
| how to access values of awk/nawk variables outside the awk/nawk block? | saniya | Shell Programming and Scripting | 5 | 05-13-2008 08:37 AM |
| AWK (NAWK) and filtering values | Nicol | UNIX for Dummies Questions & Answers | 11 | 04-23-2008 05:40 AM |
| I can't seem to pass variables properly into a nawk statement | DeCoTwc | Shell Programming and Scripting | 6 | 03-30-2008 03:07 PM |
| awk/nawk returning decimal values? | moutaye | Shell Programming and Scripting | 1 | 03-25-2008 03:04 PM |
| awk/nawk returning decimal values? | moutaye | SUN Solaris | 1 | 03-25-2008 03:02 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
is it possible to pass external variable values to nawk?
Dear friends,
please tell me how to pass the external variable values to the nawk command. length=`expr $len2 - $len1` i need to pass $length to following nawk command as mentioned below. nawk '{if((x=index($0,"W/X"))>0){id=substr($0,x, $length);print x;print id;}}' filename1 but I am getting follwing error, nawk: illegal field $() input record number 1, file filename1 source line number 1 please tell me how to pass the $length value to the nawk . waiting for ur reeply.... swamymns |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|