Skip to main content

Minimalist SQLite-based CLI tool for working with tabular data.

Project description

sqtab

sqtab is a minimalist command-line tool for working with tabular data using SQLite.
It provides a simple workflow for importing CSV/JSON files, inspecting table structures, executing SQL queries, and exporting results.
The goal is to offer a small, dependency-light utility that is easy to integrate into scripts and data pipelines.


Installation

git clone https://github.com/gojankovic/sqtab
cd sqtab
python -m venv venv
source venv/bin/activate   # Windows: venv\Scripts\activate
pip install -e .

This installs the sqtab command inside your virtual environment.


Basic Usage

Import CSV or JSON into a table

sqtab import data.csv users
sqtab import data.json users

Analyze table structure

sqtab analyze users

List tables

sqtab tables
sqtab tables --schema

Execute SQL

sqtab sql "SELECT * FROM users;"

Export tables

sqtab export users output.csv
sqtab export users output.json

Database information

sqtab info

Reset database

Soft reset (drops all tables):

sqtab reset

Hard reset (delete the database file):

sqtab reset --hard

Command Reference

The full list of commands is always available through:

sqtab --help
sqtab <command> --help

Examples:

sqtab import --help
sqtab sql --help
sqtab tables --help

Each command provides clear parameter descriptions and available options.


License

MIT License © 2025 Goran Janković

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sqtab-0.0.1.tar.gz (12.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sqtab-0.0.1-py3-none-any.whl (11.3 kB view details)

Uploaded Python 3

File details

Details for the file sqtab-0.0.1.tar.gz.

File metadata

  • Download URL: sqtab-0.0.1.tar.gz
  • Upload date:
  • Size: 12.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.0

File hashes

Hashes for sqtab-0.0.1.tar.gz
Algorithm Hash digest
SHA256 e7939a4c464a816da02ea02cccb35d35f78ad243bab9491dd78cab81eb79f803
MD5 779bc4e78f22a0d1ccde402a74a3e613
BLAKE2b-256 703295c1e48f4146f1093bc04c236e7e43942b76e98629cd093a8e478b3bf1b8

See more details on using hashes here.

File details

Details for the file sqtab-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: sqtab-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 11.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.0

File hashes

Hashes for sqtab-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8bd98bcff6d11ba2dbfe851eb3bc2bf1803ca8c19b2f90bd4af3455b6ea054b5
MD5 e90e0f6eff3ef8a8215f2533434b4a4b
BLAKE2b-256 cada6591454a7c71cabed7ba69ea17e039de1ba91494e7ebdae6ef1a1d4ff5ca

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page