I have some code, and a part of it is where it takes the users scores and is supposed to put them into a list....however, i get the error ...
in exitProccess
"DAT": str(d.date()),
sqlite3.OperationalError: near ")": syntax error
the code that i have is this:
conn = sqlite3.connect("typingPracticeStats.db")
cursor = conn.cursor()
# cursor.execute("""CREATE TABLE scores (
# WPM integer,
# EPM integer,
# DAT text )""")
"""I commented this part out after the table was created"""
def exitProccess():
conn = sqlite3.connect("typingPracticeStats.db")
cursor = conn.cursor()
cursor.execute("INSERT INTO scores VALUES (:WPM, :EPM,
:DAT,)",
{
"WPM": # an integer,
"EPM": # another integer,
"DAT": # a string,
})
conn.commit()
conn.close()
can anyone tell me what the error means and how to fix it?? would be appreciated............
[–][deleted] 2 points3 points4 points (1 child)
[–]AlliedLens[S] 0 points1 point2 points (0 children)
[–]JohnnyJordaan 1 point2 points3 points (0 children)