Veiw join & rest of table? - Mailing list pgsql-general

From Justin Lynch
Subject Veiw join & rest of table?
Date
Msg-id 379E55EF.78A0DEDF@hms.uq.edu.au
Whole thread Raw
List pgsql-general
I have two tables and I want to see all of one table plus the columns
that join to the other; eg
table1     table2
-------     ------
cola colb  cola  cold
1     a     1    g
2     b     2    h
3     c     3    i
4     d
5     e
6     f

so when I do;
select *
from table1 1, table2 2
where 1.cola=2.cola

I only get
table3
------
cola    colb    cold
1         a      g
2         b      h
3         c      i


Question:- how do I do a query to display the rest of table1 at the same
time?
ie,
4     d
5     e
6     f
(as well)

Thanks in advance
Justin Lynch

University of Queensland
jlynch@hms.uq.edu.au

pgsql-general by date:

Previous
From: ghoffman@ucsd.edu (Gary Hoffman)
Date:
Subject: Re: [GENERAL] PHP and Postgresql 6.5.1
Next
From: Randy Dees
Date:
Subject: Problems importing my 6.3 database into 6.5.1