QueryBuilder CLI allows users to run SQL queries on CSV/Excel files locally. There are two modes:
main_cli)qb_cli) with a terminal-style interfaceThe static CLI allows executing queries directly from the command line without entering an interactive shell.
python -m frontend.cli.cli_static [OPTIONS]
| Option | Alias | Description |
|---|---|---|
--file |
-f |
Path to CSV/Excel file |
--query |
-q |
SQL query to execute |
--db_engine |
-db |
SQL engine to use (sqlite, duckdb, auto) |
--cleanup |
- | Cleanup database after execution |
--store |
-s |
Save query results to result_set.csv |
python -m frontend.cli.cli_static -f data.csv -q"SELECT * FROM table LIMIT 10" -db sqlite
python -m frontend.cli.cli_static -f data.csv -q"SELECT * FROM table" -s
python -m frontend.cli.cli_static -f data.csv -q"SELECT * FROM table" --cleanup
Notes:
-db_engine is not provided or set to auto, QueryBuilder will try to select the best available engine.-store option will create a result_set.csv in the current directory.