上一条
select *
from cms_article awhere id = (select c.p
from (select t.id,lag(t.id,1,0) over(order by t.sort) as p
from cms_article t) c
where c.id = '8a3e56b6396630260139663fa32d01e1');
下一条
select a.id,a.title
from cms_article a
where id = (select c.p
from (select t.id,lead(t.id,0) over(order by t.sort,t.eidt_date) as p
from cms_article t ) c
where c.id = '8a3e56b6396630260139663fa32d01e1'); 原文链接:https://www.f2er.com/oracle/213828.html