Re: psql's FETCH_COUNT (cursor) is not being respected for CTEs

Поиск
Список
Период
Сортировка
От Daniel Verite
Тема Re: psql's FETCH_COUNT (cursor) is not being respected for CTEs
Дата
Msg-id 10117fba-890b-46ac-9316-cae83108a6a6@manitou-mail.org
обсуждение исходный текст
Ответ на Re: psql's FETCH_COUNT (cursor) is not being respected for CTEs  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: psql's FETCH_COUNT (cursor) is not being respected for CTEs  (Alexander Lakhin <exclusion@gmail.com>)
Список pgsql-hackers
    Tom Lane wrote:

> I've reconsidered after realizing that implementing FETCH_COUNT
> atop traditional single-row mode would require either merging
> single-row results into a bigger PGresult or persuading psql's
> results-printing code to accept an array of PGresults not just
> one.  Either of those would be expensive and ugly, not to mention
> needing chunks of code we don't have today.

Yes, we must accumulate results because the aligned format needs to
know the columns widths for a entire "page", and the row-by-row logic
does not fit that well in that case.
One of the posted patches implemented this with an array of PGresult
in single-row mode [1] but I'm confident that the newer version you
pushed with the libpq changes is a better approach.

> So I whacked the patch around till I liked it better, and pushed it.

Thanks for taking care of this!


[1]
https://www.postgresql.org/message-id/092583fb-97c5-428f-8d99-fd31be4a5290@manitou-mail.org


Best regards,
--
Daniel Vérité
https://postgresql.verite.pro/
Twitter: @DanielVerite



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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: documentation structure
Следующее
От: Melanie Plageman
Дата:
Сообщение: Re: PostgreSQL 17 Release Management Team & Feature Freeze