Skip to main content

SQL plugin for Bottle

Project description

BottleSQL

SQL plugin for Bottle. Supports MySQL/MariaDB and SQLite.

Installation

PyPi

pip install pip install bottle-sql==0.0.1

Source

wget https://raw.githubusercontent.com/thepure12/bottle-sql/main/src/bottle_sql/bottle_sql.py

Usage

SQL

from bottle import Bottle
from bottle_sql import sqlPlugin

app = Bottle()
user, pw, host, db = ("root", "", "localhost", "mydb")
sql_plugin = sqlPlugin(user=user, password=pw, host=host, database=db)
app.install(sql_plugin)

SQLite

from bottle import Bottle
from bottle_sql import sqlitePlugin

app = Bottle()
dbfile= ":memory:"
sql_plugin = sqlitePlugin(dbfile)
app.install(sql_plugin)

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

bottle_sql-0.0.2.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

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

bottle_sql-0.0.2-py3-none-any.whl (3.8 kB view details)

Uploaded Python 3

File details

Details for the file bottle_sql-0.0.2.tar.gz.

File metadata

  • Download URL: bottle_sql-0.0.2.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.5

File hashes

Hashes for bottle_sql-0.0.2.tar.gz
Algorithm Hash digest
SHA256 646224395f75f14f5ee01c78d910502cc1577a56490c2193b5b326f6922ad3e4
MD5 b14d1b2b83330768f8dcd3e44ee83ca5
BLAKE2b-256 42f1a52d0136048a83e7ed29881bf43c15f99b9e2dcd619fa307698fb404622f

See more details on using hashes here.

File details

Details for the file bottle_sql-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: bottle_sql-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.5

File hashes

Hashes for bottle_sql-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6512448a47ab057a3a8e8d4674ebb4dc3022ecaae9399793e25a2b82db9245a4
MD5 078515dd2b58e831556396b94f1d181e
BLAKE2b-256 99db86ae57f8e227efebb9e1e0b1f8ab1fa7d72dcd000a08d4602dadc0f0fb3a

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