| От | Gaetano Mendola |
|---|---|
| Тема | Re: How to find LIMIT in SQL standard |
| Дата | |
| Msg-id | bkn72i$hvv$1@floppy.pyrenet.fr обсуждение исходный текст |
| Ответ на | How to find LIMIT in SQL standard (Rory Campbell-Lange <rory@campbell-lange.net>) |
| Список | pgsql-general |
Rory Campbell-Lange wrote: > Essentially the call (as defined below) asks for an update and adds a > LIMIT parameter on the end of the UPDATE. (eg update where x=1 limit 1). > Postgres doesn't like this and I assume it isn't SQL standards > compliant and need to refer to this in my bug report. As far as I know you can not specify a limit for update in Postgres, at least not in that way. if you want to do UPDATE foo SET a='bar' where b LIMIT 1; this is possible in Postgres doing: UPDATE foo SET a = 'bar WHERE foo.oid IN ( SELECT f.oid FROM foo f WHERE b LIMIT 1 ); This fail if the table are created without OID. Regards Gaetano Mendola
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера