Skip to main content

alt-python-pydbc-core

Core abstraction layer for pydbc — the uniform database access library for Python.

This package provides the ABCs, registries, and generic helpers that all pydbc driver packages depend on. You do not normally install this package directly. Install the driver package for your database; alt-python-pydbc-core is pulled in automatically as a dependency.

# Install the driver for your database — core is a transitive dependency
uv add alt-python-pydbc-sqlite    # SQLite
uv add alt-python-pydbc-pg        # PostgreSQL
uv add alt-python-pydbc-mysql     # MySQL / MariaDB
uv add alt-python-pydbc-mssql     # SQL Server

What this package provides

ABCs (Abstract Base Classes)

Class Purpose
Driver Abstract base for all pydbc drivers
Connection Abstract connection handle
Statement Execute arbitrary SQL
PreparedStatement Execute pre-compiled SQL with bound parameters
ResultSet Row access after a query
DataSource Connection factory abstraction
ConnectionPool Connection pool abstraction

DriverManager

Central registry that maps connection URLs to registered drivers. Driver packages self-register at import time by calling DriverManager.register_driver().

import pydbc_sqlite  # registers SQLiteDriver
from pydbc_core import DriverManager

conn = DriverManager.get_connection("pydbc:sqlite::memory:")
stmt = conn.create_statement()
rs = stmt.execute_query("SELECT 42 AS n")
print(rs.rows)   # [(42,)]
conn.close()

GenericDbApiDriver

A reusable base driver that wraps any DB-API 2.0 module. Driver packages typically subclass this; it handles connection lifecycle, cursor management, and paramstyle normalisation automatically.

DataSource helpers

Class When to use
SingleConnectionDataSource Tests and scripts that need one persistent connection
PooledDataSource Servers and applications that need a connection pool
NamedParameterDataSource Convenience wrapper with named-parameter query/update methods

ParamstyleNormalizer

Rewrites SQL written with ? (positional) or :name (named) placeholders to whatever the underlying DB-API 2.0 driver expects (%s, %(name)s, :1, etc.). This means you write SQL once and it works against any driver.


Documentation


License

MIT

Metadata

Release files for alt-python-pydbc-core 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for alt-python-pydbc-core 1.1.0
File Size Uploaded Provenance
alt_python_pydbc_core-1.1.0.tar.gz 22.6 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for alt-python-pydbc-core 1.1.0
File Interpreter ABI Platform
alt_python_pydbc_core-1.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 44.1 kB

Release files / alt_python_pydbc_core-1.1.0.tar.gz

Download URL alt_python_pydbc_core-1.1.0.tar.gz
Size 22.6 kB
Tags Source
SHA-256 checksum
How to use checksums
40966a6d3a88025780334b5dc6dcd89b146894b087c4d04ec1ab68b7ab3575ac
BLAKE2b-256 checksum
How to use checksums
6a427b5e8b77c03e0cb23975bc080175280fe9045ff22da00604c23f2208010e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / alt_python_pydbc_core-1.1.0-py3-none-any.whl

Download URL alt_python_pydbc_core-1.1.0-py3-none-any.whl
Size 21.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fa36e982244d96ee463ffccc849d3e2778281a3c74d5e053966d2c42d70b1b03
BLAKE2b-256 checksum
How to use checksums
2f0c9f9ef323405b13679ef12328dd1e29e153cd31e4be4d9c01f3dfc09896d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for alt-python-pydbc-core 1.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page