I'm working on a discord bot in python and so far I've got it to connect and fetch queries from the database and send it to the discord server. But the output is formatted still, how do I remove the brackets/commas.
Code:
@bot.command()
async def mtop(ctx, arg1):
db = pymysql.connect(host=config.db_host, port=3306, user=config.db_user, passwd=config.db_passwd, db=config.db_name)
cur = db.cursor()
cur.execute("SELECT name FROM ck_playertimes WHERE mapname = %s AND runtimepro > -1.0 AND style = 0", (arg1,))
name = cur.fetchone()
await ctx.send(name)
cur.close()
db.close()
It outputs like this:
('Evan',)
Thank you.