awk
Grep huge number of patterns from huge file
I have a file that’s growing about 200,000 lines a day, and it is all formed with blocks of three lines as such:
Format data into a table
How can I get the details and transpose it to horizontal form?
How to manipulate a CSV file with sed or awk?
How can I do the following to a CSV file using sed or awk?
How to grep lines between start and end pattern?
I have a file which is having following content: zdk aaa b12 cdn dke kdn Input1: aaa and cdn Output 1: aaa b12 cdn Input 2: zdk and dke Output 2: zdk aaa b12 cdn dke I could use below commands to achieve: grep -a aaa -A2 file # Output 1 grep -a aaa -A4 … Read more
convert CSV to XLS file on linux
The following Perl script can convert CSV file to XLS file
Replacing missing value blank space with zero
I have input.txt tab-delimited text file around 30K lines, I would like to check each row (s1..s30K lines) for missing value (i.e blank space) and fill the missing value with zero value.See out.txt
What’s a good way to filter a text file to remove empty lines?
I have a .csv file (on a mac) that has a bunch of empty lines, e.g.:
Insert text in specific lines of a file
How can I insert some text in specific lines of a file? What is the simplest method that I can use? (bash, sed, awk?)