Skip to main content

database_wrapper_mysql

Part of the database_wrapper package.

This python package is a database wrapper for MySQL and MariaDB database.

Installation

pip install database_wrapper[mysql]

Usage

from database_wrapper_mysql import MySQL, DBWrapperMySQL

db = MySQL({
    "hostname": "localhost",
    "port": 3306,
    "username": "root",
    "password": "your_password",
    "database": "my_database"
})
db.open()
dbWrapper = DBWrapperMySQL(dbCursor=db.cursor)

# Simple query
aModel = MyModel()
res = await dbWrapper.getByKey(
    aModel,
    "id",
    3005,
)
if res:
    print(f"getByKey: {res.toDict()}")
else:
    print("No results")

# Raw query
res = await dbWrapper.getAll(
    aModel,
    customQuery="""
        SELECT t1.*, t2.name AS other_name
        FROM my_table AS t1
        LEFT JOIN other_table AS t2 ON t1.other_id = t2.id
    """
)
async for record in res:
    print(f"getAll: {record.toDict()}")
else:
    print("No results")

db.close()

Release files for database-wrapper-mysql 0.3.146

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

Source distribution (sdist)

Source distribution for database-wrapper-mysql 0.3.146
File Size Uploaded
database_wrapper_mysql-0.3.146.tar.gz 5.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for database-wrapper-mysql 0.3.146
File Interpreter ABI Platform
database_wrapper_mysql-0.3.146-py3-none-any.whl Python 3 none any Details

Total release size: 11.3 kB

Release files / database_wrapper_mysql-0.3.146.tar.gz

Download URL database_wrapper_mysql-0.3.146.tar.gz
Size 5.2 kB
Tags Source
SHA-256 checksum
How to use checksums
3373b08e05d1dcf0e9b69b18974802a874681e06b7b7b00d6725ca84ad4e3bbf
BLAKE2b-256 checksum
How to use checksums
207344fb20aec88bd417346de8408a0199d56eb8b2489bacee774b2b34895932
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 7, 2026.

Transparency log

Release files / database_wrapper_mysql-0.3.146-py3-none-any.whl

Download URL database_wrapper_mysql-0.3.146-py3-none-any.whl
Size 6.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
266885008ef0ff448b12208f16765e9a4730575371ca25314989458a26cc89b7
BLAKE2b-256 checksum
How to use checksums
6b030dfe7a46bb35be000f57e48f11a6ab0cab668cc9c5a1a5bafe5692f8dd96
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 7, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.3.146 This release

2 release files

0.2.38

2 release files

0.2.33

2 release files

0.2.32

2 release files

0.2.30

2 release files

0.2.27

2 release files

0.2.26

2 release files

0.2.23

2 release files

0.2.12

2 release files

0.2.9

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

1 release file

0.2.2

2 release files

0.1.90

2 release files

0.1.89

2 release files

0.1.87

2 release files

0.1.85

2 release files

0.1.84

2 release files

0.1.82

2 release files

0.1.80

2 release files

0.1.78

2 release files

0.1.73

2 release files

0.1.72

2 release files

0.1.44

2 release files

0.1.43

2 release files

0.1.42

2 release files

0.1.40

2 release files

0.1.38

2 release files

0.1.37

2 release files

0.1.29

1 release file

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