Skip to main content

Adapt SQLAlchemy ORM Support to web application, include flask, django, or any other web frameworks.

Project description

Adapt to Support SQLAlchemy-ROM forweb application, include flask, django, or any other web frameworks.


It is based on Flask-SQLAlchemy==2.5.1. which is extension for Flask that adds support for SQLAlchemy to your application. It aims to simplify using SQLAlchemy with Flask by providing useful defaults and extra helpers that make it easier to accomplish common tasks.

Installing

Install and update using pip:

$ pip install -U pysql-orm

A Simple Example

from flask import Flask
from pysql_orm import SQLAlchemy

app = Flask(__name__)
app.config["SQLALCHEMY_DATABASE_URI"] = "sqlite:///example.sqlite"
db = SQLAlchemy(app)


class User(db.Model):
    id = db.Column(db.Integer, primary_key=True)
    username = db.Column(db.String, unique=True, nullable=False)
    email = db.Column(db.String, unique=True, nullable=False)


db.session.add(User(name="Flask", email="example@example.com"))
db.session.commit()

users = User.query.all()

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

Pysql-ORM-2.5.5.tar.gz (23.7 kB view details)

Uploaded Source

File details

Details for the file Pysql-ORM-2.5.5.tar.gz.

File metadata

  • Download URL: Pysql-ORM-2.5.5.tar.gz
  • Upload date:
  • Size: 23.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.3

File hashes

Hashes for Pysql-ORM-2.5.5.tar.gz
Algorithm Hash digest
SHA256 ec19923c1f772639b28cd3fb4275cb7d98f2ebf1495daf191249063c033e498b
MD5 7ec67c595268f98df1ee6d221f4ce772
BLAKE2b-256 eee0ddb25196f733c729ad71b1ff1ac4c48a987fd6600a989bf8afb25db6cf5c

See more details on using hashes here.

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