SELECT @charges=ISNULL(MAX(a.maxcharge), 0.00) FROM( SELECT (SELECT MAX(maxcharge) FROM(VALUES(ilongcharge),(iwidthcharge),(iheightcharge),(iweightcharge ),(ivolumecharge)) AS maxcharge(maxcharge))AS maxcharge FROM @temp) a
原文:https://www.cnblogs.com/shuaimeng/p/10569736.html