-- 根据编号分组取第一条数据
select * from table t where t.no=(select max(no) from table t1 where t1.no=t.no)


-- 根据编号分组后取第一条数据
SELECT * FROM 
    (SELECT ROW_NUMBER() OVER (partition BY no ORDER BY no) rowId,* 
    from table) t
WHERE rowId=1


 

相关文章:

  • 2021-11-18
  • 2022-02-18
  • 2021-11-18
  • 2021-08-31
  • 2022-12-23
  • 2022-02-11
  • 2021-04-18
  • 2022-01-19
猜你喜欢
  • 2021-11-18
  • 2021-12-18
  • 2022-12-23
  • 2022-12-23
  • 2022-01-25
  • 2021-12-10
相关资源
相似解决方案