May 2000
Beginner
761 pages
18h 20m
English
Awk does not see input data as an endless string of characters, but as having a format or structure. By default, each line is called a record and is terminated with a newline.
By default, the output and input record separator (line separator) is a carriage return, stored in the built-in awk variables ORS and RS, respectively. The ORS and RS values can be changed, but only in a limited fashion.
An entire record is referenced as $0 by awk. (When $0 is changed by substitution or assignment, the value of NF, the number of fields, may be changed.) The newline value is stored in awk's built-in variable RS, a carriage return by default.
% cat employees Tom Jones ... |
Read now
Unlock full access