You can import CSV files directly into an SQLite database. Then you are free to do whatever sql searches or manipulations you want. Python and golang both have great SQLite libraries from personal experience, but I'd be surprised if there is any language that doesn't have a decent one.
If you are running Linux most distros have an SQLite gui browser in the repos that is pretty powerful.