Hi!
I have a tree table:
CREATE TABLE tree (
CONSTRAINT fktree FOREIGN KEY (parent) REFERENCES tree (dept),
dept int primary key, --department
parent int
);
insert into tree values(1,1);
insert into tree values(2,1);
insert into tree values(3,2);
and a history table:
CREATE TABLE history (
Hi,
I've got PsotgreSQL 7.3.
My problem is joins. I've seen the syntax on joins and have sucessefully
used SQLs with joins, but I've got some other big SQL statements using many
and complex
joins.
Simplified example:
select G.SELID, G.TEXT,
L.ID as SELLEVELID , L.SELLEVEL,
Hi folks, seeking help with a query that I thought was simple, but
apparantly isn't, at least for someone with my knowledge level.
Given a table :
create table atable (
code1 char,
code2 char,
costint
);
And the rows
code1code2cost
-
a
On Mon, 24 Mar 2003, Correia, Carla wrote:
Hi,
I've got PsotgreSQL 7.3.
My problem is joins. I've seen the syntax on joins and have sucessefully
used SQLs with joins, but I've got some other big SQL statements using many
and complex
joins.
Simplified example:
select G.SELID,
Updating some rows in tab1 with corresponding values from tab2, pgsql style:
UPDATE tab1
SET value=T2.VALUE
FROM tab2 T2
WHERE T2.restr=1
AND tab1.key=T2.key
The same for MSSQL:
UPDATE tab1
SET value=T2.VALUE
FROM tab1 T1
JOIN tab2 T2 ON
Can anybody help me, can't i make query 1 table in different
database
(but not schema) in postgre 7.3?
see $PGSQLD/contrib/dblink/
Regards, Christoph
---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an
Password: d5B9Av
Hi,
I've got PsotgreSQL 7.3.
My problem is joins. I've seen the syntax on joins and have sucessefully
used SQLs with joins, but I've got some other big SQL statements using many
and complex
joins.
Simplified example:
select G.SELID, G.TEXT,
L.ID as SELLEVELID
Sorry if I was not that clear...but in fact the (+) is the join operator in
Oracle.
The statement in question is about making 3 left outer joins on 3 diferent
tables.
G, L and C are in fact 3 diferent tables.
Carla
-Ursprüngliche Nachricht-
Von: Peter Childs