Skip to content

SQLite

Install

Install ibis and dependencies for the SQLite backend:

pip install 'ibis-framework[sqlite]'
conda install -c conda-forge ibis-sqlite
mamba install -c conda-forge ibis-sqlite

Connect

API

Create a client by passing in a path to a SQLite database to ibis.sqlite.connect.

See ibis.backends.sqlite.Backend.do_connect for connection parameter information.

ibis.sqlite.connect is a thin wrapper around ibis.backends.sqlite.Backend.do_connect.

Connection Parameters

do_connect(self, path=None)

Create an Ibis client connected to a SQLite database.

Multiple database files can be created using the attach() method

Parameters

path File path to the SQLite database file. If None, creates an in-memory transient database and you can use attach() to add more files

Examples

import ibis ibis.sqlite.connect("path/to/my/sqlite.db")

Backend API

Backend (BaseAlchemyBackend)

Methods

attach(self, name, path)

Connect another SQLite database file to the current connection.

Parameters

name Database name within SQLite path Path to sqlite3 database file

table(self, name, database=None)

Create a table expression from a table in the SQLite database.

Parameters

name Table name database Name of the attached database that the table is located in.

Returns

Table Table expression


Last update: March 23, 2022