def __init__(self):
dbargs = dict(
host = '127.0.0.1',
db = 'test',
user = 'root',
passwd = '123456',
cursorclass = MySQLdb.cursors.DictCursor,
charset = 'utf8',
use_unicode = True
)
self.dbpool = adbapi.ConnectionPool('MySQLdb',**dbargs)
评论列表
文章目录