"select ..... for update of ..." doesn't support full qualified table name?

From: Vlad <marchenko(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: "select ..... for update of ..." doesn't support full qualified table name?
Date: 2005-09-06 17:45:47
Message-ID: cd70c68105090610456facd8ba@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

CREATE SCHEMA one;
CREATE TABLE one.aa ( a INT );
CREATE SCHEMA two;
CREATE TABLE two.bb ( b INT );
SELECT * FROM one.aa, two.bb WHERE one.aa.a = two.bb.b FOR UPDATE OF one.aa;

ERROR: syntax error at or near "." at character 73 (points to the
last instance of "one.aa" in SQL query)

p.s. in our application we actually have the same table names but in
different schemas, so avoiding using of schema name in table reference
is not possible, so actual select looks like this:

CREATE TABLE one.t ( a INT );
CREATE TABLE two.t ( b INT );
SELECT * FROM one.t, two.t WHERE one.t.a = two.t.b FOR UPDATE OF one.t;

--
Vlad

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Oleg Bartunov 2005-09-06 17:58:35 Re: tsearch2 & unicode
Previous Message Lincoln Yeoh 2005-09-06 16:56:12 Re: Setting up a database for 10000 concurrent users