I get an error message 55000 when I try to traverse backwards in an refcursor. Works fine going forward. The hint says I need to use scroll. What is the syntax for using scroll in a stored procedure that returns an refcursor? Or do refcursors only support traversing forward?
"Karen Hill" <karen_hill22@yahoo.com> writes:
> I get an error message 55000 when I try to traverse backwards in an
> refcursor. Works fine going forward. The hint says I need to use
> scroll. What is the syntax for using scroll in a stored procedure that
> returns an refcursor? Or do refcursors only support traversing forward?
AFAICS the SPI cursor code only supports the old "backward compatible"
behavior, which is that you can do backward scans only if the query plan
supports them as-is. You might be able to force this by adding an ORDER
BY to the query to force a top-level sort.
regards, tom lane
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера