testid = 69
query = """SELECT * FROM basic_info WHERE ownerid=%s"""
cur.execute(query, testid)
print cur.fetchone()
I am getting an integer error when attempting this. I have tried converting testid to a string with no luck.
The second paraemter of Cursor.execute should be a sequence (tuple or list) or a mapping (dict):
testid = 69
query = """SELECT * FROM basic_info WHERE ownerid=%s"""
cur.execute(query, [testid]) # <--
print cur.fetchone()