1. sqlitebiter¶
1.1. Summary¶
sqlitebiter is a CLI tool to convert CSV / Excel / HTML / JSON / Jupyter Notebook / LDJSON / LTSV / Markdown / SQLite / SSV / TSV / Google-Sheets to a SQLite database file.
1.2. Features¶
- Create a SQLite database file from:
- File(s):
CSV / Tab separated values (TSV) / Space separated values (SSV)
Microsoft Excel TM
HTML
- JSON
See also: Limitations of JSON conversion
Line-delimited JSON(LDJSON) / NDJSON / JSON Lines
Markdown
Mediawiki
SQLite
URL (scrape tabular data from web pages)
Multi-byte character support
Automatic file encoding detection
2. Installation¶
2.1. Installation: pip (Python package manager)¶
pip install sqlitebiter
2.2. Installation: apt¶
You can install the package by apt
via a Personal Package Archive (PPA):
sudo add-apt-repository ppa:thombashi/ppa
sudo apt update
sudo apt install sqlitebiter
2.3. Installation: dpkg (.deb
package)¶
The following commands will download the latest .deb
package from the release page, and install it.
curl -sSL https://raw.githubusercontent.com/thombashi/sqlitebiter/master/scripts/installer.sh | sudo bash
2.4. Installation: Windows¶
sqlitebiter
can be used in Windows environments without Python installation as follows:
Navigate to https://github.com/thombashi/sqlitebiter/releases
Download the latest version of the
sqlitebiter_win_x64.zip
Unzip the file
Execute
sqlitebiter.exe
in either Command Prompt or PowerShell
2.5. Installation: Windows (PowerShell)¶
The following commands will download the latest execution binary from the release page to the current directory.
wget https://github.com/thombashi/sqlitebiter/raw/master/scripts/get-sqlitebiter.ps1 -OutFile get-sqlitebiter.ps1
Set-ExecutionPolicy Unrestricted -Scope Process -Force; .\get-sqlitebiter.ps1
2.6. Installation: brew for macOS¶
$ brew tap thombashi/sqlitebiter
$ brew install sqlitebiter
2.7. Command Completion (bash/zsh)¶
setup command completion for bash:
sqlitebiter completion bash >> ~/.bashrc
setup command completion for zsh:
sqlitebiter completion zsh >> ~/.zshrc
3. Dependencies¶
Python 3.7+
3.1. Python package dependencies¶
3.1.1. Google Sheets dependencies (Optional)¶
Extra Python packages are required to install to use the Google Sheets feature (gs subcommand):
The extra packages can be installed with the following pip command;
$ pip install sqlitebiter[gs]
note: binary packages include these dependencies
3.1.2. Misc dependencies (Optional)¶
3.2. Dependencies other than Python packages (Optional)¶
libxml2
(faster HTML/Markdown conversion)pandoc (required when converting MediaWiki files)