Search Postgresql Archives

Re: problem in joins

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On mán, 2006-11-20 at 11:23 +0530, deepak pal wrote:
>   i am facing problem in joining three table...there are two columns
> comman in two table..is it nessary to use both these two column..in
> where caluses.........

as a rule, yes.

create table t1 (a1 int ,b1 int, c1 int);
create table t2 (a2 int ,b2 int, d2 int);

if first 2 columns are common, you would:
  select * from t1 JOIN t2 ON ((a1=a2) and (b1=b2));

not sure what your problem with third table is.

if this does not answer your question, please
provide us with an example of what you mean.

gnari






[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux