Skip to main content

EnDATA Object Relational Mapper

Project description

EnORM

EnORM - EnDATA Object Relational Mapper. Get ready for an EnORMous database experience!

Example usage

from EnORM import Column, DBConnection, Table


c1 = Column(
    col_name='ID',
    vartype='integer',
    max_l=None,
    default=None,
    null=False,
    unique=True,
    p_key=True,
    autoinc=True
)
c2 = Column(
    col_name='fname',
    vartype='varchar',
    max_l=20
)
c3 = Column(
    col_name='lname',
    vartype='varchar',
    max_l=20
)
c4 = Column('age', 'integer')
users_table = Table('users', c1, c2, c3, c4)
with DBConnection('operations.db') as db:
    db.create_table(users_table)
    db.insert('users', ['Nima', 'Bavari', 27], ['fname', 'lname', 'age'])
    db.insert('users', ['Omid', 'Armagar', 32], ['fname', 'lname', 'age'])
    db.update('users', ['age'], [35], ['fname'], ['Omid'])
    db.get_all('users', ['fname', 'lname'], ['age'], [35],
               order_by=[{'name': 'lname', 'desc': False}])

Project details


Download files

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

Files for EnORM, version 0.1.0
Filename, size File type Python version Upload date Hashes
Filename, size EnORM-0.1.0-py3-none-any.whl (5.7 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size EnORM-0.1.0.tar.gz (4.4 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page