CockroachDB into Apache Arrow with ADBC
CockroachDB 26, read and written through adbcBridge — the ADBC driver that loads the database's ODBC driver — verified on Linux, macOS arm64 and Windows x64. Everything below is the compatibility matrix's record for this row.
Status
PASS
PASS (CockroachDB, PostgreSQL wire 18.0.0, arm64)
PASS (CockroachDB, PostgreSQL wire 18.0.0; psqlodbc 18.00.0002)
Driver and connection string
- ODBC driver
- psqlodbc 16 (PG wire)
- Wire
- PostgreSQL wire
- adbcBridge
- 0.1.1 (release)
The connection string the matrix used, as the connection strings reference records it (PostgreSQL wire); {drv} is the driver library or its name from odbcinst.ini, and the host, port and credentials are the test server's.
Driver={drv};Server=127.0.0.1;Port=16257;Database=defaultdb;Uid=root;
Python
import adbcbridge
# {drv}: the ODBC driver library (path), or its name from odbcinst.ini
conn = adbcbridge.connect(uri="Driver={drv};Server=127.0.0.1;Port=16257;Database=defaultdb;Uid=root;")
with conn.cursor() as cur:
cur.execute("SELECT * FROM my_table")
table = cur.fetch_arrow_table() # pyarrow.Table
Polars and pandas
import polars as pl, pandas as pd
df = pl.read_database("SELECT * FROM my_table", connection=conn) # Polars, Arrow-native
pdf = pd.read_sql("SELECT * FROM my_table", conn) # pandas 2.2+, ADBC connection
pip install adbcbridge brings the driver library; the CockroachDB ODBC driver is installed the way its vendor documents, then named in Driver=. Rust, Go, C# and Java use the same connection string through their ADBC driver managers — see the docs.
What the matrix recorded
no quirks; declare a PRIMARY KEY or the synthesised hidden rowid shows up in GetObjects; version() is CockroachDB's own, so the PostgreSQL array-ingest form stays off and ingest uses the multi-row INSERT (verified); no ctid (42703), so partitioned reads use the key-range split — measured 5.1x at N=8 and 6.5x at N=16 over a single connection on 1 M rows. adbc_driver_postgresql cannot read this server at all (it needs binary COPY TO, which CockroachDB does not implement), so there is no native ADBC alternative to compare against
Native ADBC driver, compared
CockroachDB speaks the PostgreSQL wire protocol, so Apache Arrow's native PostgreSQL ADBC driver (adbc-driver-postgresql 1.12.0) can be pointed at it too. On 2026-09-05 the same seven-step ADBC workload (connect, SELECT 1, DDL and inserts and a read, a 1,000-row adbc_ingest, table schema, catalog listing, read back) ran through both:
| Path | Result | First error |
|---|---|---|
| Native ADBC driver | fails at select1 | INVALID_ARGUMENT: [libpq] Failed to execute query: could not begin COPY: ERROR: unimplemented: binary format |
| adbcBridge over ODBC | ✓ all seven steps |
Where the native driver stops it is by design of that driver, not a defect of CockroachDB; the full table for all 28 wire-compatible databases, with each first error, is in the note.