Install usql
usql is one program, usql (usql.exe on Windows). Every way to install it below gives you every database driver. Pick the tab for your system.
- Download the file for your system from the releases of usql.
- Extract
usqlorusql.exefrom the.tar.bz2or.zipfile. - Move the program to a directory in your
PATH(Linux and macOS) or%PATH%(Windows).
Homebrew works on macOS and Linux:
brew install xo/xo/usqlFor the ODBC databases, add the tap and install with ODBC:
brew tap xo/xobrew install --with-odbc usqlOn Arch Linux, install usql from the AUR. usql-bin installs the released program:
yay -S usql-binusql builds it from source, which takes much longer because it compiles every driver:
yay -S usqlgo install github.com/xo/usql@latestThe image docker.io/usql/usql works with Docker, Podman and the other container runtimes. This command opens the SQLite file data/test.db of the current directory:
docker run --rm -it --volume "$(pwd)/data:/data" docker.io/usql/usql:latest sqlite3://data/test.dbMake sure that it works
Section titled “Make sure that it works”usql --versionusql prints its version. Continue with First steps.