dsq: Commandline tool for running SQL queries against JSON, CSV, Excel, Parquet, and more
October 19, 2023
#development #golang #reading-list #sql #sqlite #tools
🔗 dsq: Commandline tool for running SQL queries against JSON, CSV, Excel, Parquet, and more
datastation.multiprocess.io
dsq is a commandline tool for running SQL queries against all the data file types that DataStation supports (JSON, CSV, Parquet, Excel, etc.). Here is a simple example:
$ cat users.csv name,age Jorge,30 Nina,32 Cal,28 Mona,27 $ dsq users.csv "SELECT * FROM {} ORDER BY CAST(age AS INT) DESC" | jq [ { "age": "32", "name": "Nina" }, { "age": "30", "name": "Jorge" }, { "age": "28", "name": "Cal" }, { "age": "27", "name": "Mona" } ]
dsq uses DataStation libraries under-the-hood and DataStation in turn uses SQLite for these kinds of queries.
The dsq source code is available on Github.
continue reading on datastation.multiprocess.io
⚠️ This post links to an external website. ⚠️
If this post was enjoyable or useful for you, please share it! If you have comments, questions, or feedback, you can email my personal email. To get new posts, subscribe use the RSS feed.