Category Archives: Sed Command

Sed Command Tutorial: Common Usage Examples

How to using multiple delimiters in awk and sed

Multiple delimiter-separated fields in awk or sed.
Using awk command:
➜ awk -F'[:=|]’ ‘{print $1, $2, $3}’ test.log;
Using sed command:
➜ sed ‘s/[:=|]/ /g’ test.log Continue reading

Posted in Awk Command, File & Directory, How to, Sed Command, Text Processing | Tagged , , , , , , | 3 Comments

use the linux command to find the max value and print

Mostly used for log processing, there are several ways: first way: awk -v, second way: awk+sort+head, Third way: sed+sort+head, fourth way: sort -t+head … Continue reading

Posted in Awk Command, Sed Command | Comments Off on use the linux command to find the max value and print