如何把这个改成UPDATE语句,谢谢!
sql="select 明细表.编码,b.clzj as 材料单价,round(b.clzj*数量,2) as 材料总价,b.jjgs as 机加单件工时,round(b.jjgs*数量,2) as 机加单台工时,b.dqgs as 电气单件工时,round(b.dqgs*数量,2) as 电气单台工时 into hz from 明细表 inner join (SELECT 上级编码,sum(材料总价) as clzj,sum(机加单台工时) as jjgs,sum(电气单台工时) as dqgs FROM 明细表 group by 上级编码) b on 明细表.编码=b.上级编码"