pgpool
Install
pip3 install pypostgrestool==0.1
Usage
from pg_client import PostgresDB
db = PostgresDB(host="127.0.0.1", port=5432, user='postgres',
password='123456', db_name=my-db', min_conn=10,
max_conn=100)
# search
sql = "select * from my-tab"
print(db1.query_all(sql=sql))
Singleton
db1 = PostgresDB(host="127.0.0.1", port=5432, user='postgres',
password='123456', db_name=my-db', min_conn=10,
max_conn=100)
db2 = PostgresDB(host="127.0.0.1", port=5432, user='postgres',
password='123456', db_name=my-db', min_conn=10,
max_conn=100)
print(db1)
print(db2)
print(db1.pool)
print(db2.pool)
Release files for pypostgrestool 0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| pypostgrestool-0.1.tar.gz | 1.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| pypostgrestool-0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 5.1 kB
Release files / pypostgrestool-0.1.tar.gz
| Download URL | pypostgrestool-0.1.tar.gz |
|---|---|
| Size | 1.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f69b6563dbd8c0a001b9c78ef23b6acb251e76123a5fac136753648beb5b06bd
|
|
BLAKE2b-256 checksum How to use checksums |
9be2d5d867117e823f36c75d0a6e336dbbbe5421cbd6676fec09e4b25c1be310
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.3
|
Release files / pypostgrestool-0.1-py3-none-any.whl
| Download URL | pypostgrestool-0.1-py3-none-any.whl |
|---|---|
| Size | 3.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b106f292fe162c471380c9ab78af7ba2f5fe162c4261bfcc9514ed837145e45f
|
|
BLAKE2b-256 checksum How to use checksums |
2466219658eb715249c39c4ada653f9883a19ac6dde2fc60e8f80cb3446aa669
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/47.3.1 requests-toolbelt/0.9.1 tqdm/4.46.1 CPython/3.7.3
|