If you like the idea of this but aren't on Linux or want something with a little ui involved, check out the Rainbow CSV extension for VS Code, vim, Sublime, and Atom. It includes RBQL [0] which lets you query CSVs with a sql-like syntax.
(Not affiliated with Rainbow CSV or RBQL at all, just a happy user)
[0]: https://rbql.org/