Skip to main content

Python database orm functions for Locobuzz, common code that is required in all projects

Project description

Database ORM package

This package provide a way to implement the ORM using the sync and aysnc way and easily used with the

Installation

Install the package using pip:

pip install locobuzz-python-orm
pip install locobuzz-python-orm[dataframe]

Usage

Basic Usage

connection_string = f"mssql+aioodbc://{username}:{encoded_password}@{host}/{database}?driver=ODBC+Driver+17+for+SQL+Server"
db = AsyncDatabase(connection_string, min_connections=1, max_connections=1)
query = text("SELECT * FROM mstCategories")

async with db as database:
    result = await database.query_tuples(query)
    print(result)  # List of tuples output

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

locobuzz_python_orm-1.0.1.tar.gz (4.4 kB view hashes)

Uploaded Source

Built Distribution

locobuzz_python_orm-1.0.1-py3-none-any.whl (6.5 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page