Re: To Postgres Devs : Wouldn't changing the select limit

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: To Postgres Devs : Wouldn't changing the select limit
Дата
Msg-id Pine.LNX.4.30.0110201152350.827-100000@peter.localdomain
обсуждение исходный текст
Ответ на Re: To Postgres Devs : Wouldn't changing the select limit  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: To Postgres Devs : Wouldn't changing the select limit
Список pgsql-general
Tom Lane writes:

> ERROR:  LIMIT #,# syntax no longer supported.  Use LIMIT # OFFSET #.
>     If translating pre-7.2 Postgres: LIMIT m,n => LIMIT m OFFSET n
>     If translating MySQL: LIMIT m,n => OFFSET m LIMIT n

I think someone is panicking here for no reason, but I'm not sure who it
is.  If we think that LIMIT x,y should be phased out, then let's add that
to the documentation and remove it in a later release, so people have a
chance to prepare.  But you're removing a perfectly fine feature that has
received no attention in the last two years on the last day before beta
because of a mysterious crowd of people porting from MySQL.  Let me tell
you:  People porting from MySQL are going to have a lot of other problems
before they find out that LIMIT works differently.

In addition I want to repeat my object to notices and errors that are
teaching syntax or trying to give smart tips.  If a command is not
syntactically correct then it's a syntax error.  If the command used to be
correct, might be correct in the future, or is correct in some other life
then it's still a syntax error.  If we want to have a "tip mode" then
let's have one, but until that happens the documentation is the place to
explain error messages or give advice how to avoid them.

Now, of course this whole situation is a bit unfortunate because of the
syntax mixup.  But let's remember that most people that are going to use
PostgreSQL 7.2 are the people that are using PostgreSQL 7.1 now, and
they're going to be a lot happier the less they're going to be annoyed by
gratuitous breaks in compatibility that had no prior notice at all.

--
Peter Eisentraut   peter_e@gmx.net   http://funkturm.homeip.net/~peter


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

Предыдущее
От: "Andre Schnabel"
Дата:
Сообщение: Re: Bug in pg_dump/pg_restore
Следующее
От: "Dinesh Parikh"
Дата:
Сообщение: Query On Case structure