OFS on AWk not working
Hi,
on 10.6.7 with latest updates the output field separator is not working.
Example
$ echo a b c d | awk '{ OFS = ":";print $0}'
results in:
a b c d
instead of:
a:b:c:d
Mac OS X (10.6.7)
Hi,
on 10.6.7 with latest updates the output field separator is not working.
Example
$ echo a b c d | awk '{ OFS = ":";print $0}'
results in:
a b c d
instead of:
a:b:c:d
Mac OS X (10.6.7)
Hi,
already solved by mysqlf. I could remember $0 was working in that case. Workaround:
echo a b c d | awk '{ OFS = ":";print $1,$2,$3,$4}'
thanks Paul
OFS on AWk not working