I have the following code and it works, but I need to understand why there is a comma after the variable id_to_remove, can someone explain to me why that has to be there? (I bolded the part I don't understand)
def delete_user(id_to_remove):
sql = "DELETE FROM USERS WHERE ID = ?"
conn = create_connection()
cursor = conn.cursor()
**cursor.execute(sql, (id_to_remove, ))**
conn.commit()
conn.close()
So I don't know why its id_to_remove, and not just cursor.execute(sql,(id_to_remove))