Skip to content

Commit

Permalink
Add example, related #930
Browse files Browse the repository at this point in the history
  • Loading branch information
James McKinney committed Mar 7, 2018
1 parent ca62599 commit 36248b0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/scripts/csvsql.rst
Original file line number Diff line number Diff line change
Expand Up @@ -111,3 +111,7 @@ Group rows by one column::
You can also use CSVSQL to "directly" query one or more CSV files. Please note that this will create an in-memory SQL database, so it won't be very fast::

csvsql --query "select m.usda_id, avg(i.sepal_length) as mean_sepal_length from iris as i join irismeta as m on (i.species = m.species) group by m.species" examples/iris.csv examples/irismeta.csv

Concatenate two columns::

csvsql --query "select a||b from 'dummy3'" examples/dummy3.csv

0 comments on commit 36248b0

Please sign in to comment.