pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jeroen T. Vermeulen <jtv@xs4all.nl>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-hackers@postgresql.org
Cc: pgsql-sql@postgresql.org
Subject: Re: Cursors and backwards scans and SCROLL
Date: Mon, 10 Mar 2003 16:32:46 +0100
Message-ID: <20030310153245.GW98248@xs4all.nl> (raw)
In-Reply-To: <21621.1047242111@sss.pgh.pa.us>
References: <21621.1047242111@sss.pgh.pa.us>

On Sun, Mar 09, 2003 at 03:35:11PM -0500, Tom Lane wrote:
> 
> 2. Error out only if a backwards fetch is actually attempted on a plan
> tree that can't handle it (which could only happen if SCROLL wasn't
> given).  This is efficient and flexible, but it exposes implementation
> details to the user, in that whether an error occurs will depend on
> which plan the system happens to choose.  

I wouldn't worry too much about exposing implementation details at 
present--the existing situation does the same, except it pretends that
not returning data that should be there isn't an error.  Absent any
further documentation, I'd call that a bug that needs to be fixed.


> There are cases where
> identical cursor definitions might allow or not allow backwards fetch
> depending on the planner's choices.  Notice though that errors could
> occur only in cases that would silently fail in the present code; so
> existing applications that work reliably would not see such errors.

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"?


Jeroen




view thread (15+ messages)  latest in thread

Message-ID: <20030310153245.GW98248@xs4all.nl>
Permalink:  ../20030310153245.GW98248@xs4all.nl/
Also on:    postgresql.org/message-id/20030310153245.GW98248@xs4all.nl

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: jtv@xs4all.nl, tgl@sss.pgh.pa.us, pgsql-hackers@postgresql.org
  Subject: Re: Cursors and backwards scans and SCROLL
  In-Reply-To: <20030310153245.GW98248@xs4all.nl>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox