itemBank = [] for row in rows: itemBank.append(( tempRow2['Item_Name'], tempRow1['Item_Price'], tempRow3['Item_In_Stock'], tempRow4['Item_Max'], getTimeExtra )) #append dataq = """ insert ignore into TABLE1 ( Item_Name, Item_Price, Item_In_Stock, Item_Max, Observation_Date ) values (%s,%s,%s,%s,%s) """try: x.executemany(q, itemBank) conn.commit()except: conn.rollback()
希望对您有帮助
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)