sqlalchemy-orm


Namesqlalchemy-orm JSON
Version 1.2.10 PyPI version JSON
download
home_pagehttps://gitlab.com/parob/sqlalchemy-orm
SummaryData Relation Mapping framework for Python.
upload_time2023-05-20 09:18:19
maintainer
docs_urlNone
authorRobert Parker
requires_python
licenseMIT
keywords sqlalchemy orm
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # SQLAlchemy-ORM
ORM framework for Python. Designed for simplicity, based on [SQLAlchemy](https://www.sqlalchemy.org/).

[![coverage report](https://gitlab.com/parob/sqlalchemy-orm/badges/master/coverage.svg)](https://gitlab.com/parob/sqlalchemy-orm/commits/master)

[![pipeline status](https://gitlab.com/parob/sqlalchemy-orm/badges/master/pipeline.svg)](https://gitlab.com/parob/sqlalchemy-orm/commits/master)


Check out the tests directory for more examples.

## Basic Example
``` python
from sqlalachemy_orm import Model, Database

Base = Model()

class Animal(Base):
    name: str
    age: int

db = Database("sqlite:///:memory:") # use an in-memory SQLite database
db.create(Animal)  # Create the `Animal` table in the database

bea = Animal(name="bea", age=5)

session = db.session()
session.create(bea) # Create a row in the `Animal` table

print(session.query(Animal).filter(Animal.name == "bea").one())

session.commit() # commit the session to the database
```

``` text
$ python example.py
>>> Animal(name='bea', age=5)
```

            

Raw data

            {
    "_id": null,
    "home_page": "https://gitlab.com/parob/sqlalchemy-orm",
    "name": "sqlalchemy-orm",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "SQLAlchemy,ORM",
    "author": "Robert Parker",
    "author_email": "rob@parob.com",
    "download_url": "https://files.pythonhosted.org/packages/c8/98/b0451ae949f8b16287965d4fc4a180fae50a78d9b186300e135ec22e1883/sqlalchemy-orm-1.2.10.tar.gz",
    "platform": null,
    "description": "# SQLAlchemy-ORM\nORM framework for Python. Designed for simplicity, based on [SQLAlchemy](https://www.sqlalchemy.org/).\n\n[![coverage report](https://gitlab.com/parob/sqlalchemy-orm/badges/master/coverage.svg)](https://gitlab.com/parob/sqlalchemy-orm/commits/master)\n\n[![pipeline status](https://gitlab.com/parob/sqlalchemy-orm/badges/master/pipeline.svg)](https://gitlab.com/parob/sqlalchemy-orm/commits/master)\n\n\nCheck out the tests directory for more examples.\n\n## Basic Example\n``` python\nfrom sqlalachemy_orm import Model, Database\n\nBase = Model()\n\nclass Animal(Base):\n    name: str\n    age: int\n\ndb = Database(\"sqlite:///:memory:\") # use an in-memory SQLite database\ndb.create(Animal)  # Create the `Animal` table in the database\n\nbea = Animal(name=\"bea\", age=5)\n\nsession = db.session()\nsession.create(bea) # Create a row in the `Animal` table\n\nprint(session.query(Animal).filter(Animal.name == \"bea\").one())\n\nsession.commit() # commit the session to the database\n```\n\n``` text\n$ python example.py\n>>> Animal(name='bea', age=5)\n```\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Data Relation Mapping framework for Python.",
    "version": "1.2.10",
    "project_urls": {
        "Download": "https://gitlab.com/parob/sqlalchemy-orm/-/archive/v1.2.10/sqlalchemy-orm-v1.2.10.tar.gz",
        "Homepage": "https://gitlab.com/parob/sqlalchemy-orm"
    },
    "split_keywords": [
        "sqlalchemy",
        "orm"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c898b0451ae949f8b16287965d4fc4a180fae50a78d9b186300e135ec22e1883",
                "md5": "2e5d3a2b10394722e2419aa08d73e79c",
                "sha256": "7ab46d2a54a429d4fd384df9a37ad639dc87ff93be5205ed649c5ca4dad164bb"
            },
            "downloads": -1,
            "filename": "sqlalchemy-orm-1.2.10.tar.gz",
            "has_sig": false,
            "md5_digest": "2e5d3a2b10394722e2419aa08d73e79c",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 21846,
            "upload_time": "2023-05-20T09:18:19",
            "upload_time_iso_8601": "2023-05-20T09:18:19.064252Z",
            "url": "https://files.pythonhosted.org/packages/c8/98/b0451ae949f8b16287965d4fc4a180fae50a78d9b186300e135ec22e1883/sqlalchemy-orm-1.2.10.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-05-20 09:18:19",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "parob",
    "gitlab_project": "sqlalchemy-orm",
    "lcname": "sqlalchemy-orm"
}
        
Elapsed time: 0.08564s