Re: incorrect syntax for offset

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: incorrect syntax for offset
Дата
Msg-id 6423.1250636199@sss.pgh.pa.us
обсуждение исходный текст
Ответ на incorrect syntax for offset  (Jaime Casanova <jcasanov@systemguards.com.ec>)
Список pgsql-docs
Jaime Casanova <jcasanov@systemguards.com.ec> writes:
> i read that as allow me to use the ROWS in an OFFSET clause whatever i
> use LIMIT or FETCH for limiting results but seems like we try hard to
> make a distinguish from old syntax and new (sql standard) syntax

> pruebas=# select * from tab1 limit 3 offset 2 rows;
> ERROR:  syntax error at or near "rows"
> LINE 1: select * from tab1 limit 3 offset 2 rows;
>                                             ^
> pruebas=# select * from tab1 offset 2 fetch next 3 rows only;
> ERROR:  syntax error at or near "fetch"
> LINE 1: select * from tab1 offset 2 fetch next 3 rows only;

Hmm.  Seems like we could refactor the select_limit production so it
actually allows all the reasonable combinations.  Let me have a look...

            regards, tom lane

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

Предыдущее
От: Jaime Casanova
Дата:
Сообщение: incorrect syntax for offset
Следующее
От: Bruno Guimarães Carneiro
Дата:
Сообщение: Doc 8.4 Part 2 - Cap 6 : Data Manipulation ( about Triggers and Rewrite Rules )