我試圖使用SQL函數Rank()來獲取列表幾個組的最高記錄。這裏是什麼即時通訊特林不起作用: select hc.hId, hc.DpId, hc.Rank
from (
select d.hId, DpId, Rank()
OVER (Partition by DpId ORDER BY d.hId) AS Rank
FROM CurDp d
INNER
create table tab1(sno int, name varchar(30), age int);
insert into tab1 values(1, 'abc1', 22);
insert into tab1 values(2, 'abc2', 23);
insert into tab1 values(3, 'xyz', 28);
insert into tab1 valu