我的SQL在运行时给我错误
import sqlite3
conn = sqlite3.connect("test.db")
cursor1 = conn.cursor()
cursor1.execute("CREATE TABLE IF NOT EXISTS TEST2 (a int, b text, c dates)")
conn.commit()
cursor1.execute("""INSERT INTO TEST2 VALUES (b='Hello World', c= ?""",(1,))
conn.commit()
,错误代码:
Traceback (most recent call last):
File "C:/Users/Green/Desktop/Py Proj/DataBase test.py", line 9, in <module>
cursor1.execute("""INSERT INTO TEST2 VALUES (b='Hello World', c= ?""",(1,))
sqlite3.OperationalError: near "?": syntax error