【发布时间】:2012-03-01 17:06:49
【问题描述】:
我正在尝试连续更新多个项目,我的代码如下:
updateQuery = "UPDATE Throughput SET Test_Date = '%s' , Iperf11ntcpUL = '%s' , Iperf11ntcpDL = '%s' , Iperf11nudpUL = '%s' , Iperf11nudpDL = '%s' , HttpDL = '%s' , HttpUL = '%s', notes2='%s' where DeviceName = '%s' and Buildinfo ='%s' and Band = '%s' and Buildtype = '%s' " %(date, data['Iperf 11N TCP UL'], data['Iperf 11N TCP DL'], data['Iperf 11N UDP UL'], data['Iperf 11N UDP DL'], data['HTTP DL'],data['HTTP UL'],data['Notes'], data['Device Name'], data['Build Info / No.'], data['Band'], data['Build Type'])
cursor.execute(updateQuery)
执行此代码时出现以下错误:
Previous SQL was not a query.
【问题讨论】: