for row in sql database python loop

Solutions on MaxInterview for for row in sql database python loop by the best coders in the world

showing results for - "for row in sql database python loop"
Francesca
13 Mar 2016
1import sqlite3
2conn = sqlite3.connect('file.txt') 
3cur = conn.cursor()
4cur.execute('''
5CREATE TABLE Table (first TEXT, second INTEGER)''')
6	#Do things with Table
7for row in cur.execute('SELECT * FROM Table') :
8	print(row)
9cur.close()