diff --git a/dbtools/__init__.py b/dbtools/__init__.py index 5ff001d..ffca253 100644 --- a/dbtools/__init__.py +++ b/dbtools/__init__.py @@ -14,7 +14,7 @@ class dbObject: def initMySQL(self, host, port, user, pwd, db): self.conn = pymysql.connect(host = host, port = port, user = user, password = pwd, db = db, charset = "utf8mb4", cursorclass = pymysql.cursors.DictCursor) - self.cur = conn.cursor() + self.cur = self.conn.cursor() self.dbtype = MYSQL self.host = host self.port = port