Re: ResultSet storing all rows with defaulftFetchSize to 5000

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: ResultSet storing all rows with defaulftFetchSize to 5000
Дата
Msg-id 3558.1518451137@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: ResultSet storing all rows with defaulftFetchSize to 5000  (Vladimir Sitnikov <sitnikov.vladimir@gmail.com>)
Ответы Re: ResultSet storing all rows with defaulftFetchSize to 5000
Список pgsql-jdbc
Vladimir Sitnikov <sitnikov.vladimir@gmail.com> writes:
> I have no idea why PostgreSQL closes all the cursors as transaction
> ends,

Because the SQL standard says so.  If a cursor isn't declared WITH HOLD,
then it's implicitly closed at transaction commit, cf SQL:2011 4.33
"Cursors": 

    An open cursor that was not defined as a holdable cursor is also
    closed by a <commit statement>.

Also, 14.2 <cursor properties> says that WITHOUT HOLD is the default
assumption if you don't explicitly say WITH HOLD.

(Yes, we do support WITH HOLD.)

            regards, tom lane


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

Предыдущее
От: Vladimir Sitnikov
Дата:
Сообщение: Re: ResultSet storing all rows with defaulftFetchSize to 5000
Следующее
От: Jaime Soler
Дата:
Сообщение: Re: ResultSet storing all rows with defaulftFetchSize to 5000