#NEWLINE# def fetchall_dicts( cursor ) : #NEWLINE# #INDENT# columns = [ x [ 0 ] for x in cursor . description ] #NEWLINE# rows = [ ] #NEWLINE# for row in cursor . fetchall ( ) : #NEWLINE# #INDENT# rows . append ( dict ( zip ( columns , row ) ) ) #NEWLINE# #UNINDENT# return rows