Re: Support for grabbing multiple consecutive values with nextval()
В списке pgsql-hackers по дате отправления:
| От | Ronan Dunklau |
|---|---|
| Тема | Re: Support for grabbing multiple consecutive values with nextval() |
| Дата | |
| Msg-id | 2516352.Lt9SDvczpP@aivenronan обсуждение исходный текст |
| Ответ на | Re: Support for grabbing multiple consecutive values with nextval() (Jille Timmermans <jille@quis.cx>) |
| Список | pgsql-hackers |
Hello, Reading the thread, I think the feature has value: it would basically transfer control of the sequence cache to the client application. However, I don't think that returning only the last value is a sensible thing to do. The client will need to know the details of the sequence to do anything useful about this, especially it's increment, minvalue, maxvalue and cycle options. As suggested upthread, returning a resultset would probably be better. If the client application is concerned about the volume of data exchanged with the server, and is willing to deal with handling the knowledge of the sequence details themselves, they can always wrap it in an aggregate: SELECT min(newvals), max(newvals) FROM nextvals(<num_nextvals>) as newvals Regards, -- Ronan Dunklau
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера