User Tools

Site Tools


csvgrep_notes

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
csvgrep_notes [2021/07/20 21:29] rajucsvgrep_notes [2021/07/20 21:37] (current) – [sample commands] raju
Line 1: Line 1:
 +==== sample commands ====
 +<code>
 +csvgrep -c col1 -m "val1" file.csv | \
 +csvgrep -c col2 -r "foo|bar" | \
 +csvcut -c col1,col2,col3 | \
 +column -t -s,
 +</code>
 +
 +demonstrates | regex a or b
 +
 +Ref:- https://dl.icewarp.com/online_help/203030104.htm - Simple RegEx Tutorial. It talks about the '|' OR operator in regex. For example "foo|bar" matches a string that has either "foo" or "bar" in it.
 +
 ==== useful links ==== ==== useful links ====
   * https://csvkit.readthedocs.io/en/1.0.6/scripts/csvgrep.html   * https://csvkit.readthedocs.io/en/1.0.6/scripts/csvgrep.html
csvgrep_notes.1626816546.txt.gz · Last modified: 2021/07/20 21:29 by raju