Re: Cursors and backwards scans and SCROLL

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Cursors and backwards scans and SCROLL
Дата
Msg-id 17531.1047310893@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Cursors and backwards scans and SCROLL  ("Jeroen T. Vermeulen" <jtv@xs4all.nl>)
Ответы Re: Cursors and backwards scans and SCROLL  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-hackers
"Jeroen T. Vermeulen" <jtv@xs4all.nl> writes:
>> There are cases where
>> identical cursor definitions might allow or not allow backwards fetch
>> depending on the planner's choices.

> Would it be possible to give warnings in a narrow superset of the
> problematic cases, something along the lines of "I'm scrolling backwards
> for you now, but there's no reason why that should work on this same query 
> tomorrow"?

I don't see a practical way to do that --- that little bit of warning
code would have to embed a lot of fragile assumptions about the set of
alternatives searched by the planner.  It would probably break every
time we improved the planner.  And the breakage would consist either of
failing to give a warning when one is appropriate, or giving a warning
when no other plan is really likely to be chosen; neither of which are
going to be easily noticed or tested for.  Seems like a losing game :-(
        regards, tom lane


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

Предыдущее
От: "Jeroen T. Vermeulen"
Дата:
Сообщение: Re: Cursors and backwards scans and SCROLL
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Who puts the Windows binaries on the FTP server?