![]() |
|
|
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. |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
awk question
Hi
I have the following command: grep -w ${PX} fmembit_3.dta | awk '{print $2}' The problem is that every time I need to print a different field. The value of the field is stored in variable FIELD: FIELD=2 Is there a way to make awk use ${FIELD} instead of $2 ? May be somebody knows the way arond it. Thanks a lot -A |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|