Re: Simplyfying many equals in a join - Mailing list pgsql-general

From Randall Skelton
Subject Re: Simplyfying many equals in a join
Date
Msg-id 6990CCA2-685E-11D8-A229-000393C92230@brutus.uwaterloo.ca
Whole thread Raw
In response to Simplyfying many equals in a join  (Randall Skelton <skelton@brutus.uwaterloo.ca>)
List pgsql-general
Thanks... like so many other things, that seems obvious now.

On 25 Feb 2004, at 21:22, Jim Wilson wrote:

> Like this:
>
> select tq1.timestamp as t, tq1.value as q1, tq2.value as q2,
>  tq3.value as q3, tq4.value as q4 from
>  cal_quat_1 tq1, cal_quat_2 tq2, cal_quat_3 tq3, cal_quat_4 tq4
>  where tq1.timestamp = tq2.timestamp
>  and   tq2.timestamp = tq3.timestamp
>  and   tq3.timestamp = tq4.timestamp
>  and tq1.timestamp > '2004-01-12 09:47:56.0000 +0'::timestamp with
> timezone
>  and tq1.timestamp < '2004-01-12 09:50:44.7187 +0'::timestamp with
> timezone
>  order by tq1.timestamp;
>
> The "and" makes anything more reduntant.
>
> Best,
>
> Jim Wilson


pgsql-general by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: postgreSQL licenseing
Next
From: Tom Lane
Date:
Subject: Re: help using arrays in a function