[GENERAL] Query optimization question

From: Ed Loehr <ELOEHR(at)austin(dot)rr(dot)com>
To: pg-gen <pgsql-general(at)postgresql(dot)org>
Subject: [GENERAL] Query optimization question
Date: 1999-12-20 07:51:05
Message-ID: 385DDFE9.8BB91CB7@austin.rr.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Which is faster? This...

SELECT t1.name
FROM t1, t2, t3, t4
WHERE
t1.id = 1 AND
t2.id = 2 AND
t3.id = 3 AND
t3.id = t4.id;

...or this...

SELECT t1.name
FROM t1, t2, t3, t4
WHERE
t1.id = 1 AND
t3.id = t4.id AND
t2.id = 2 AND
t3.id = 3;

Does it make a difference in pgsql?

Cheers,
Ed Loehr

Browse pgsql-general by date

  From Date Subject
Next Message Jose Soares 1999-12-20 13:51:23 Re: [GENERAL] copy command -- foiled by pg_atoi
Previous Message Egon Schmid 1999-12-20 05:11:47 Re: [GENERAL] dynamic queries in Postgres