getting the last N tuples of a query

Поиск
Список
Период
Сортировка
От Edmundo Robles L.
Тема getting the last N tuples of a query
Дата
Msg-id 252EE06031407243B058CF7699226E3A0F89A3@mail2.sensacd.com.mx
обсуждение исходный текст
Ответы Re: getting the last N tuples of a query  (Ben Chobot <bench@silentmedia.com>)
Список pgsql-general
Hi!

if a want the first   5,10,N tuples  of a query  (even without order)
i just  have to do a:
select  * from table limit 10;


but, What can i do to get the last  10 tuples ???
  i try to do:
select * from table limit -10;  :-D  but  that query  return 0 tuples .

So, what is the right way to do that  with no order????



В списке pgsql-general по дате отправления:

Предыдущее
От: "Carlo Stonebanks"
Дата:
Сообщение: Re: No PL/PHP ? Any reason?
Следующее
От: Ben Chobot
Дата:
Сообщение: Re: getting the last N tuples of a query