Out put is not in dictionary format

조회수 56회
읽지 않은 첫 메시지로 건너뛰기

Mitra

읽지 않음,
2016. 5. 31. 오전 11:43:0516. 5. 31.
받는사람 PyMySQL Users
After installing pymysql , I copied the example from here https://github.com/PyMySQL/PyMySQL#requirements  and ran it ,however the output is 

(1, 'very-secret') instead of {'password': 'very-secret', 'id': 1


What is missing? 

Thank you,
Mitra

Naoki INADA

읽지 않음,
2016. 6. 1. 오후 10:11:4616. 6. 1.
받는사람 PyMySQL Users
# Connect to the database
connection
= pymysql.connect(host='localhost',
                             
user='user',
                             
password='passwd',
                             
db='db',
                             
charset='utf8mb4',
                             
cursorclass=pymysql.cursors.DictCursor)

Did you really copy the example?
`cursorclass=pymysql.cursors.DictCursor` is where specifying what returned from cursor.
전체답장
작성자에게 답글
전달
새 메시지 0개