sql5="select id from lie_shipping_intermediate_data where purchase_item_id = "+"'"+str(purchase_item_id)+"'"+" and "+"warehouse_receipt_sn = "+"'"+str(warehouse_receipt_sn)+"'"+" and "+"source_type = "+"2"
cursor.execute(sql5)
result5=cursor.fetchall()
iflen(result5)!=0:
delete_sql="delete from lie_shipping_intermediate_data where id = "+str(result5[0][0])+" limit 1"
sql5="select id from lie_shipping_intermediate_data where purchase_item_id = "+"'"+str(purchase_item_id)+"'"+" and "+"warehouse_receipt_sn = "+"'"+str(warehouse_receipt_sn)+"'"+" and "+"source_type = "+"2"
cursor.execute(sql5)
result5=cursor.fetchall()
iflen(result5)!=0:
delete_sql="delete from lie_shipping_intermediate_data where id = "+str(result5[0][0])+" limit 1"