How to limit rows in PostgreSQL SELECT

前端 未结 5 970
盖世英雄少女心
盖世英雄少女心 2021-02-06 20:21

What\'s the equivalent to SQL Server\'s TOP or DB2\'s FETCH FIRST or mySQL\'s LIMIT in PostgreSQL?

5条回答
  •  日久生厌
    2021-02-06 21:05

    Apart from limit you could use Fetch First as well. Your question already had the answer

    Select * from users FETCH FIRST 5 ROWS ONLY
    

提交回复
热议问题