Use DictCursor ouf oursql to get better readability in MYSQL_RED_PAGE
This commit is contained in:
@@ -46,7 +46,7 @@ class MYSQL_RED_PAGE( MYSQL_RED ):
|
||||
@returns tuple Tuple with data for given page_id otherwise if none found
|
||||
bool FALSE
|
||||
"""
|
||||
cursor = type( self ).connection.cursor()
|
||||
cursor = type( self ).connection.cursor(mysqldb.DictCursor)
|
||||
|
||||
format_str = """SELECT * FROM `red_pages` WHERE page_id={page_id};"""
|
||||
query = format_str.format( page_id=int( page_id ) )
|
||||
|
||||
Reference in New Issue
Block a user