Re: [HACKERS] FETCH without FROM/IN

From: Thomas Lockhart <lockhart(at)alumni(dot)caltech(dot)edu>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Michael Meskes <meskes(at)postgreSQL(dot)org>, PostgreSQL Hacker <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: [HACKERS] FETCH without FROM/IN
Date: 2000-01-12 16:43:07
Message-ID: 387CAF1B.A4F9466B@alumni.caltech.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> Looking at the SQL92 spec, it seems we are mighty far away from any
> defensible reading of the spec :-(...
> Are we compatible with anything at all???

Although not rigorously compatible, it appears that we do allow
compatible syntax:

FETCH 4 FROM t1;
FETCH NEXT FROM t1;

But afaik our cursor behavior does not currently allow supporting

FETCH FIRST FROM t1; -- cursor can't be positioned to first/last
FETCH ABSOLUTE 4 FROM t1; -- not sure about this one...
FETCH RELATIVE 4 FROM t1; -- this could be a MOVE/FETCH combination?

so we, uh, don't support it (yet).

I'd suggest definitely supporting all SQL92 syntax that the cursor can
manage, and also supporting the existing Postgres behaviors (which may
only be a simple subset). If we have just *alternate* syntax for the
same thing, then v7.0 would be a good time to straighten it up.

- Thomas

--
Thomas Lockhart lockhart(at)alumni(dot)caltech(dot)edu
South Pasadena, California

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Meskes 2000-01-12 16:53:26 Re: [HACKERS] FETCH without FROM/IN
Previous Message Thomas Lockhart 2000-01-12 16:26:05 Re: [HACKERS] Re: [SQL] createdb -D xxxx not working