Skip to main content

A simple ORM for Python

Project description

Orbit-Orator

A simple ORM for Python, forked from Orator.

Installation

pip install orbit-orator

Basic Usage

from orbit_orator import DatabaseManager, Model

config = {
    'mysql': {
        'driver': 'mysql',
        'host': 'localhost',
        'database': 'database',
        'user': 'root',
        'password': '',
        'prefix': ''
    }
}

db = DatabaseManager(config)
Model.set_connection_resolver(db)

class User(Model):
    pass

users = User.where('votes', '>', 100).take(10).get()

for user in users:
    print(user.name)

License

MIT License

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

orbit_orator-0.9.9.11.tar.gz (116.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

orbit_orator-0.9.9.11-py3-none-any.whl (169.8 kB view details)

Uploaded Python 3

File details

Details for the file orbit_orator-0.9.9.11.tar.gz.

File metadata

  • Download URL: orbit_orator-0.9.9.11.tar.gz
  • Upload date:
  • Size: 116.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for orbit_orator-0.9.9.11.tar.gz
Algorithm Hash digest
SHA256 50c6ed3ef6000b9327f903634bafbac9c35b977ed804bc06f432bae42798b305
MD5 3b5178de5c005fc0fa592951aa5765eb
BLAKE2b-256 f096870ab4dc01f7f62c1d161ebaae12d85e2400e33ef293fccc107ec5894f78

See more details on using hashes here.

File details

Details for the file orbit_orator-0.9.9.11-py3-none-any.whl.

File metadata

File hashes

Hashes for orbit_orator-0.9.9.11-py3-none-any.whl
Algorithm Hash digest
SHA256 8eb1ab85a10bd87e67f69199ecbc2b5bb36f8bf40f9f26270192774a8779c187
MD5 eba6d3a00447cfd4397e938575ebe83a
BLAKE2b-256 3569027df3d89ffe2a1c1b074a31c2e065c1e0b273ec5defa4cb63473d84b33e

See more details on using hashes here.

Supported by

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