You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Behavior change: CSV now follows RFC 4180. -i csv no longer interprets \n, \t and \\ inside quoted fields ("C:\new" stays C:\new), and keeps a lone \r inside a field (only the \r of a CRLF line ending is dropped). -o csv and escape_csv()/escape("csv", s) keep line breaks inside quotes instead of writing \n/\t, also quote fields with \r or leading/trailing spaces, and -o csv ends records with \n instead of \r\n (use -v 'ORS=\r\n' for CRLF)
Add PROCINFO["sorted_in"] support for for (k in arr): all of gawk's predefined orders (@ind_str_asc, @ind_num_desc, @val_num_asc, @val_type_desc, ...). A user-defined comparison function is a fatal error instead of being silently ignored
IGNORECASE now also applies, as in gawk, to string comparisons (==, !=, <, ..., and switch string cases) and index(), comparing Unicode characters case-insensitively, and to single-character regex literals such as split(s, a, /x/). A single-character string separator (FS = "x", split(s, a, "x")) stays literal
Add gawk's switch statement: switch (expr) { case 1: ... case "str": ... case /regex/: ... default: ... }. Numeric and string labels are compared with ==, regex labels with ~; a body falls through to the next case unless it ends with break, and continue applies to the enclosing loop. Duplicate case values and a duplicate default are syntax errors, as in gawk
Add f-string interpolation: f"Hello, {name}", f"{$1} at line {NR}". Only variable names and field references ({$1}, {$NF}) are substituted; {{/}} are literal braces
Add JSON Lines input format -i jsonl (alias ndjson): keys of the first record populate FI, e.g. zawk -i jsonl '{ print $FI["name"] }' demo.jsonl
Add parquet input format -i parquet: keys of the first record populate FI, e.g. zawk -i parquet '{ print $FI["name"] }' demo.parquet