layout | title |
---|---|
home |
chDB |
chDB is an embedded SQL OLAP Engine powered by ClickHouse
- In-process SQL OLAP Engine, powered by ClickHouse
- No need to install ClickHouse
- Minimized data copy from C++ to Python with python memoryview
- Input&Output support Parquet, CSV, JSON, Arrow, ORC and 60+more formats, samples
python3 -m chdb SQL [OutputFormat]
python3 -m chdb "SELECT 1,'abc'" Pretty
Currently, chDB only supports query
function, which is used to execute SQL and return desired format data.
import chdb
res = chdb.query('select version()', 'Pretty'); print(res.data())
Experimental chdb
binding examples:
Please install the latest libchdb dynamic library (amd64 only)
wget -qO- https://chdb-io.github.io/chdb-io.gpg | sudo tee /etc/apt/trusted.gpg.d/chdb-io.gpg >/dev/null
echo "deb [arch=all signed-by=/etc/apt/trusted.gpg.d/chdb-io.gpg] https://chdb-io.github.io/deb stable main" | sudo tee /etc/apt/sources.list.d/chdb-io.list >/dev/null
apt update && apt install libchdb
wget -qO- https://chdb-io.github.io/chdb-io.repo | sudo tee /etc/yum.repos.d/chdb-io.repo >/dev/null
yum install -y libchdb
wget https://github.com/metrico/libchdb/releases/latest/download/libchdb.zip
unzip libchdb_amd64.zip
mv libchdb.so /usr/lib/libchdb.so