def showData(self):
# connect to MySQL
conn, cursor = self.connect()
self.useGuiDB(cursor)
# execute command
cursor.execute("SELECT * FROM books")
print(cursor.fetchall())
cursor.execute("SELECT * FROM quotations")
print(cursor.fetchall())
# close cursor and connection
self.close(cursor, conn)
#------------------------------------------------------
GUI_MySQL_class.py 文件源码
python
阅读 27
收藏 0
点赞 0
评论 0
评论列表
文章目录