sqlite 您没有为绑定7提供值

s71maibg  于 2022-11-14  发布在  SQLite
关注(0)|答案(1)|浏览(214)

我有“您没有提供绑定7的值”错误,然而,我已经检查了类似的问题,但似乎没有一个问题与我面临的问题相同。

con = sqlite3.connect('SchoolDB.db')
cursors = con.cursor()

cursors.execute("""INSERT INTO PARENTS (STUDENT_ID, FIRST_NAME, SURNAME,GENDER,DOB,QUALIFICATION,EMAIL,PHONE_CODE, MOBILE, OCCUPATIONS) VALUES(:sid,:pfn,:psn,:pgdr,:pdob,:qlf,:pem,:ppcd,:pmb,:ocp)""",{"sid":student_id,"pfn":ParentName, "psn":ParentSurname,"pgdr":ParentGender, "pdob":ParentDOB, "qlf":ParentQualification, "epm":ParentEmail, "ppcd":ParentPhoneCode, "pmb":ParentMobile, "ocp":ParentOccupation})

con.commit()

相关问题