update  dbo.maeel00h , dbo.Sheet1  set dbo.maeel00h.el_size=dbo.Sheet1.规格型号 + '   ' + dbo.Sheet1.工艺  where  dbo.Sheet1.物料编码 = dbo.maeel00h.el_no  and  dbo.Sheet1.工艺 IS NOT NULL

解决方案 »

  1.   

    SQL里不能直接去同时更新两个表,语法是错的你需要两个update完成你的更新!或者在某个表上建立触发器去更新另一张表。
      

  2.   

    update dbo.maeel00h set dbo.maeel00h.el_size=dbo.Sheet1.规格型号 + ' ' + dbo.Sheet1.工艺 from dbo.Sheet1 where dbo.Sheet1.物料编码 = dbo.maeel00h.el_no and dbo.Sheet1.工艺 IS NOT NULL
      

  3.   

    或者
    update a set a.el_size=b.规格型号 + ' ' + b.工艺 from dbo.maeel00h a, dbo.Sheet1 b where b.物料编码 = a.el_no and b.工艺 IS NOT NULL