Skip site navigation (1) Skip section navigation (2)

Does "USING" work?

From: "Michael Labhard" <ince(at)pacifier(dot)com>
To: pgsql-cygwin(at)postgresql(dot)org
Subject: Does "USING" work?
Date: 2002-08-29 14:54:16
Message-ID: aklcg4$tp8$1@main.gmane.org (view raw or flat)
Thread:
Lists: pgsql-cygwin
Tried this simple test without success.  psql says (\h SELECT) that it
should work.  Do I have the syntax wrong?

CREATE TABLE a(
 x INTEGER PRIMARY KEY
 , y INTEGER
);

CREATE TABLE a1(
 x INTEGER REFERENCES a(x)
 , z INTEGER
);

INSERT INTO a(x, y) VALUES (1, 1);
INSERT INTO a(x, y) VALUES (2, 2);
INSERT INTO a1(x, z) VALUES (2, 2);


SELECT a.x, a.y, a1.z
FROM USING( x )
WHERE a.x = a1.x
;

DROP TABLE a;
DROP TABLE a1;






pgsql-cygwin by date

Next:From: Jason TishlerDate: 2002-08-29 16:18:27
Subject: Re: HELP < 63 users
Previous:From: daveduddDate: 2002-08-29 14:12:19
Subject: !!!!!!80!!!!

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group