Helper funcs and tools for working with SQL in mysql or postgresql
Project description
About
This is meant to be a simple way to explore a postgresql/mysql database and get data out (super light wrapper to SQLAlchemy).
Connect with DB url in the following formats:
postgresql://someuser:somepassword@somehost/somedatabase
mysql://someuser:somepassword@somehost/somedatabase
Note: This package uses pymysql driver for connecting to mysql. Urls that start with mysql:// will automatically be changed to use mysql+pymysql://.
Install
$ pip3 install sql-helper
Usage
In [1]: from sql_helper import SQL In [2]: sql = SQL('postgresql://someuser:somepassword@somehost/somedatabase') In [3]: table_names = sql.get_tables() In [4]: results = sql.execute('SELECT ...')
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for sql_helper-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d183eefe49c78e03effd3708cc91d6e7a26f9ddf7e79516c724561d79b5bd152 |
|
MD5 | 2abd0b9dcb72cc2fd174536330c5e212 |
|
BLAKE2b-256 | 3291b7d215b064c4f069e4bae21d5d7317c5b54be48ebeb2ddf21d49d0dbb920 |