十分想念顺店杂可。。。
运行环境:
系统: win10
Python版本: Python 3.6.6
SQLAlchemy的作用是:类/对象—>SQL语句—>通过pymysql/MySQLdb模块—>提交到数据库执行,这里我只介绍线程池,需要看orm介绍和使用请往别处,谢谢
安装:
pip install sqlalchemy
简单使用
# -*- coding: utf-8 -*-
# @Time : 2019/10/15 9:34
# @Author : 甄超锋
# @Email : 4535@sohu.com
# @File : test.py
# @Software: PyCharm
from sqlalchemy import create_engine
from sqlalchemy.orm import sessionmaker
import configparser
sql_conn_dict = = {
"host": "127.0.0.1",
"user": "root",
"passwd": "123456",
"db": "test",
"port": 3306,
"charset"<