I need help!! I have written a python code which queries the database and prints the result in the Linux shell prompt here is the code :
#!/usr/bin/python
import MySQLdb
import sys
import config
import csv
db = MySQLdb.connect(config.host,config.user,config.password,config.dbname)
cursor=db.cursor()
print "Connected to the Mysql database"
cursor.execute("use " + config.dbname)
cursor.execute('SELECT DISTINCT LEARNER FROM EMS_data LIMIT 5')
result= cursor.fetchall()
print result
db.commit()
cursor.close()
This is what i get :
(("'Fang ",), ("'Nikhil '",), ("'Gavin '",), ("'Vamsi'",), ("'Shah'",))
How to remove these braces..?