Re: Why UPDATE gl SET gl.glnum = gl.glnum; cause error

From: Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>
To: David Gagnon <dgagnon(at)siunik(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Why UPDATE gl SET gl.glnum = gl.glnum; cause error
Date: 2005-07-08 14:12:28
Message-ID: 20050708070921.G53562@megazone.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Fri, 8 Jul 2005, David Gagnon wrote:

> Hi all,
>
> I was juste wondering why the following code don't work:
> UPDATE gl SET gl.glnum = gl.glnum
> ERROR: column "gl" of relation "gl" does not exist
>
> While the following works:
> UPDATE gl SET glnum = glnum;
>
> Query returned successfully: 177 rows affected, 281 ms execution time.
>
> the TABLE.COLUMN is not in the SQL standard ?

For at least 92 (and I'm almost certain 99) not in the SET list. It uses
column name (which is a plain identifier) rather than a column reference.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruno Wolff III 2005-07-08 14:12:58 Re: Why UPDATE gl SET gl.glnum = gl.glnum; cause error when UPDATE gl SET glnum = glnum; is OK ?
Previous Message David Gagnon 2005-07-08 13:59:03 Why UPDATE gl SET gl.glnum = gl.glnum; cause error when UPDATE gl SET glnum = glnum; is OK ?