A database tool
Project description
This is a database tool class, do database link pool, support batch insert and query, based on PooledDB, code encapsulation, simplify the operation of development.
# pool=PooledDBhelper({ # ‘host’: ‘192.168.0.1’, # ‘user’: ‘username’, # ‘password’: ‘password’, # ‘port’: 3306, # ‘db’: ‘db_name’ # })
# data_list= [{“name”:’a’, ‘info’:’1’}, {“name”:’b’, ‘info’:’2’},{“name”:’none’, ‘info’:’3’}] # rows=pool.insert_many(data_list,”cy_self_test”) # print(rows)
# result_list=pool.task(“select * from cy_self_test”) # print(result_list)
# query = “insert into cy_self_test`({}) values {}”.format(“`name,`info`”, (“cy”,”world”)) # pool.fetchone(query)
# query=”select * from cy_self_test where id=1” # result=pool.fetchone(query) # print(result)
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file PooledDBhelper-1.0.0-py2.py3-none-any.whl.
File metadata
- Download URL: PooledDBhelper-1.0.0-py2.py3-none-any.whl
- Upload date:
- Size: 3.8 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fe2164965d577d13585a5360cd512d964e61e0577ef5af10f27b54ede0cb47bb
|
|
| MD5 |
c1757965b530fc4bf946cbe11557df5e
|
|
| BLAKE2b-256 |
286fdeb7f682453d5786cc3269bfb77024f318b07c8d96ba540a1686412096b4
|