delete from bussinessrecords where Id in (select maxid from (select max(Id) as maxid from bussinessrecords where cardsn='10000007')dddd) ;select maxid from (select max(Id) as maxid from bussinessrecords where cardsn='10000007') dddd ;'结果为22delete from bussinessrecords where Id in (22) ;为什么第一个SQL不能执行呢(MYSQL下),而第二个和第三个都没问题,具体错误提示是:
You can't specify target table 'bussinessrecords ' for update in FROM clause