Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import mysql.connector
- cnx = mysql.connector.connect(user='root', password='1111',
- host='127.0.0.1',
- database='test')
- cursor = cnx.cursor()
- cursor.execute('SELECT * FROM saif ')
- rows = cursor.fetchall()
- for row in rows:
- print row
- cnx.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement