awk:awk_field_separator_delimiters
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
awk:awk_field_separator_delimiters [2021/01/06 15:26] – peter | awk:awk_field_separator_delimiters [2022/06/13 09:41] (current) – peter | ||
---|---|---|---|
Line 5: | Line 5: | ||
< | < | ||
10 | 10 | ||
- | 11 | + | 11 |
12 | 12 | ||
13 | 13 | ||
Line 16: | Line 16: | ||
===== Specifying Input Field Separator Delimiter ===== | ===== Specifying Input Field Separator Delimiter ===== | ||
- | To set an alternative field delimiter, issue the following command: | + | To set an alternative field delimiter: |
<code awk> | <code awk> | ||
Line 30: | Line 30: | ||
<WRAP info> | <WRAP info> | ||
**NOTE: | **NOTE: | ||
- | </ | ||
+ | * AWK **FS** is any single character or regular expression which you want to use as a input field separator. | ||
+ | * AWK **FS** can be changed any number of times, it retains its values until it is explicitly changed. | ||
+ | * If you want to change the field separator, its better to change before you read the line; so the change affects the line that is read. | ||
+ | |||
+ | </ | ||
---- | ---- | ||
Line 37: | Line 41: | ||
===== Specifying Output Field Separator Delimiter ===== | ===== Specifying Output Field Separator Delimiter ===== | ||
- | To set an alternative field delimiter for the output, issue the following command: | + | To set an alternative field delimiter for the output: |
<code awk> | <code awk> | ||
Line 43: | Line 47: | ||
</ | </ | ||
- | which will display something like: | + | returns: |
< | < |
awk/awk_field_separator_delimiters.1609946806.txt.gz · Last modified: 2021/01/06 15:26 by peter