PostgreSQL

Install dependencies for Ibis’s PostgreSQL dialect:

pip install ibis-framework[postgres]

Create a client by passing a connection string to the url parameter or individual parameters to ibis.postgres.connect():

con = ibis.postgres.connect(
    url='postgresql://postgres:postgres@postgres:5432/ibis_testing'
)
con = ibis.postgres.connect(
    user='postgres',
    password='postgres',
    host='postgres',
    port=5432,
    database='ibis_testing',
)

API

The PostgreSQL client is accessible through the ibis.postgres namespace.

Use ibis.postgres.connect with a SQLAlchemy-compatible connection string to create a client.

connect([host, user, password, port, …])

Create an Ibis client located at user:password`@`host:port connected to a PostgreSQL database named database.

PostgreSQLClient.database([name])

Connect to a database called name.

PostgreSQLClient.list_tables([like, …])

List tables/views in the current or indicated database.

PostgreSQLClient.list_databases()

PostgreSQLClient.table(name[, database, schema])

Create a table expression that references a particular a table called name in a PostgreSQL database called database.