]> git.datanom.net - pwp.git/blame - app/DB/mysqld.py
Half way through migration away from sqlalchemy
[pwp.git] / app / DB / mysqld.py
CommitLineData
e5424f29
MR
1import mysql.connector as mysql
2from base import Base
3
4class Mysql(Base):
5 def __init__(self, database, user, password, host, port):
6 if port is None:
7 port = 3306
8 try:
9 self.conn = mysql.connect(database=database, user=user, password=password, host=host, port=port)
10 except mysql.Error as e:
11 raise Exception(e)
This page took 0.035191 seconds and 5 git commands to generate.