OceanBase Python Client
A OceanBase client for the Python programming language.
OceanBase is an enterprise distributed relational database with high availability, high performance, horizontal scalability, and compatibility with SQL standards.
Installation
pip install oceanbase_py
SQLAlchemy Usage
To connect to OceanBase using SQLAlchemy, use a connection string (URL) following this pattern:
- User: User Name
- Password: Password
- Host: host
- Port: port
- Database: Database Name
Here's what the connection string looks like:
oceanbase://<User>:<Password>@<Host>:<Port>/<Database>
oceanbase_py://<User>:<Password>@<Host>:<Port>/<Database>
oceanbase://<User>:<Password>@<Host>:<Port>/<Owner>
oceanbase_py://<User>:<Password>@<Host>:<Port>/<Owner>
Example
It is recommended to use python 3.x to connect to the OceanBase database, eg:
from sqlalchemy import create_engine
from sqlalchemy.schema import Table, MetaData
from sqlalchemy.sql.expression import select, text
engine = create_engine('oceanbase://root:xxx@localhost:8081/db')
connection = engine.connect()
rows = connection.execute(text("SELECT * FROM test")).fetchall()
Limits
- Oracle tenants are not currently supported.
Metadata
Release files for oceanbase-py 0.0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| oceanbase_py-0.0.1.2.tar.gz | 9.3 kB | Without provenance | Details for oceanbase_py-0.0.1.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| oceanbase_py-0.0.1.2-py3-none-any.whl | Python 3 | none | any | Details for oceanbase_py-0.0.1.2-py3-none-any.whl |
Total release size: 21.0 kB
Release files / oceanbase_py-0.0.1.2.tar.gz
| Download URL | oceanbase_py-0.0.1.2.tar.gz |
|---|---|
| Size | 9.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a0af29a49bfbc7dafb9d1c686189b8607269ffc53382ba82fd7eb9ce287f2e70
|
|
BLAKE2b-256 checksum How to use checksums |
27e17bc5c99ebdf4e486eaf89cd80d93bbe6737060668b504cbd706e4657a529
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.6
|
Release files / oceanbase_py-0.0.1.2-py3-none-any.whl
| Download URL | oceanbase_py-0.0.1.2-py3-none-any.whl |
|---|---|
| Size | 11.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8f507cb8e3ea4f150e0ae74971cc7b1a34c649af020c34fb82d85e661b5a8fc5
|
|
BLAKE2b-256 checksum How to use checksums |
9f31471360146ab62829d8ed74d49c86a900f3919b897bdf1b599b99d249a022
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.9.6
|
Security for oceanbase-py 0.0.1.2
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.