Re: table alias

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bob(dot)Henkel(at)hartfordlife(dot)com
Cc: pgsql-hackers-win32(at)postgresql(dot)org
Subject: Re: table alias
Date: 2004-05-25 14:52:50
Message-ID: 23102.1085496770@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers-win32

Bob(dot)Henkel(at)hartfordlife(dot)com writes:
> When I try an update like the one below I get the error that follows.

> update report_base s
> set s.sql_base = 'select * from test_data where'
> where s.report_base_id = 1;

> ERROR: syntax error at or near "s" at character 20

This is correct per SQL standard. There are some other databases that
allow an alias for the UPDATE target, but not Postgres.

regards, tom lane

In response to

Browse pgsql-hackers-win32 by date

  From Date Subject
Next Message Merlin Moncure 2004-05-25 20:53:11 another optimizer bug?
Previous Message Bob.Henkel 2004-05-25 14:43:47 Re: table alias