Re: Repetitive code

From: Greg Stark <gsstark(at)mit(dot)edu>
To: "Aaron Bono" <postgresql(at)aranya(dot)com>
Cc: Joe <dev(at)freedomcircle(dot)net>, pgsql-sql(at)postgresql(dot)org
Subject: Re: Repetitive code
Date: 2006-06-16 15:57:13
Message-ID: 87lkrx6qli.fsf@stark.xeocode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


"Aaron Bono" <postgresql(at)aranya(dot)com> writes:

> I haven't stared at your query as long as you have so I may have missed
> something

Likewise I'm perhaps speaking too quickly, but at the risk of making a fool of
myself: you should perhaps realize that UNION has to do a fair amount of work
to eliminate duplicates. If you know the rows are going to be distinct or if
you don't care about duplicates you can save a lot of time by using UNION ALL
instead.

--
greg

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message PFC 2006-06-16 20:21:06 Re: sessions and prepared statements
Previous Message Joe 2006-06-16 15:12:22 Re: Repetitive code