Re: Indexing UNIONs

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: Bruno Wolff III <bruno(at)wolff(dot)to>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Indexing UNIONs
Date: 2002-07-18 17:30:22
Message-ID: 200207181030.22754.josh@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


Bruno,

> My suggestion:
> SELECT t3.id, coalesce(t1.name, t2.name), t1.abbreviation,
> coalesce(t1.juris_id, t2.juris_id) from
> (t3 left join t1 using (id)) left join t2 using (id);

Cool! I didn't think of that. I'll give it a try.

-Josh

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Joseph Syjuco 2002-07-18 21:47:21 how do i import my sql query result to a file
Previous Message Christoph Haller 2002-07-18 16:22:00 Re: How to find out if an index is unique?