pupu-sqlalchemy-clickhouse 0.1.5

Last updated:

0 purchases

pupu-sqlalchemy-clickhouse 0.1.5 Image
pupu-sqlalchemy-clickhouse 0.1.5 Images
Add to Cart

Description:

pupusqlalchemyclickhouse 0.1.5

ClickHouse dialect for SQLAlchemy.

Installation
The package is installable through PIP:
pip install sqlalchemy-clickhouse


Usage
The DSN format is similar to that of regular Postgres:
>>> import sqlalchemy as sa
>>> sa.create_engine('clickhouse://username:password@hostname:port/database')
Engine('clickhouse://username:password@hostname:port/database')
For SSL add ssl parameter to URL:
>>> import sqlalchemy as sa
>>> sa.create_engine('clickhouse://username:password@hostname:port/database?ssl=True')
Engine('clickhouse://username:password@hostname:port/database')
It implements a dialect, so there’s no user-facing API.


Testing
The dialect can be registered on runtime if you don’t want to install it as:
from sqlalchemy.dialects import registry
registry.register("clickhouse", "base", "dialect")

License:

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Customer Reviews

There are no reviews.