Posts

Showing posts from October, 2018

awk: multiple delimiters

$ awk - F "#|_" '{print $2}' file how am Where the files are numbered as follows: hello#how_are_you i#am_very#well_thank#you ^^^^^ ^^^ ^^^ ^^^ ^ ^^ ^^^^ ^^^^ ^^^^^ ^^^ 1 2 3 4 1 2 3 4 5 6

Sorting according to a column

sort - t _ - k 2 - g data . file -t separator -k key/column -g general numeric sort