| | |
awk output separators?
Please support our Shell Scripting advertiser: Programming Forums - DaniWeb Sister Site
![]() |
Shell Scripting Syntax (Toggle Plain Text)
awk '{print $1 "-" $2 "-" $3}'
Java Programmer and Sun Systems Administrator
----------------------------------------------
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.
--Brian Kernighan
----------------------------------------------
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.
--Brian Kernighan
Shell Scripting Syntax (Toggle Plain Text)
$ echo "a b c"|awk '$1=$1' OFS="-" a-b-c
Shell Scripting Syntax (Toggle Plain Text)
$ echo "a b c"|awk '{print $1,$3}' OFS="-" a-c
Last edited by radoulov; Jun 21st, 2007 at 11:01 am. Reason: Addition
![]() |
Similar Threads
- awk "for loop" and variables (Shell Scripting)
- awk script (Shell Scripting)
- Replacing text within a file using awk (Shell Scripting)
- Shell Scripting problem and related awk issues (Shell Scripting)
- Help with SED/AWK email parser (Shell Scripting)
Other Threads in the Shell Scripting Forum
- Previous Thread: read line is stripping leading spaces
- Next Thread: Description for non 0 Exit codes in detail
| Thread Tools | Search this Thread |
Tag cloud for Shell Scripting






