select *
from table1
where id>
(select max(id)
from table1
where userid<>(select userid
from table1
where id = (select max(id) from table1)))
这样写是有点太麻烦了,最好写存储过程,或在程序里分步实现。
from table1
where id>
(select max(id)
from table1
where userid<>(select userid
from table1
where id = (select max(id) from table1)))
这样写是有点太麻烦了,最好写存储过程,或在程序里分步实现。
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货