尝试使用了isnull(arg1,arg2)函数表示无效

最后运用了COALESCE(arg1,arg2,arg3,...)

该函数标识返回参数中第一个不为null的值.

update  a

set

a.overplus=a.howMany -

(

select COALESCE(sum(b.USENUMBER),0)  

from b

where b.belongAFId = a.id

)

相关文章:

  • 2021-09-08
  • 2021-06-05
  • 2022-12-23
  • 2022-12-23
  • 2021-08-09
  • 2022-12-23
  • 2021-05-26
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案