赞
踩
update TbTest set lastdate= isnull(s.maxDate, TbTest.lastdate)from (select bigid, max(addDt) maxDate from TbTestB group by bigid) swhere TbTest.id = s.bigid