Re: UNION help - Mailing list pgsql-general

From Scott Marlowe
Subject Re: UNION help
Date
Msg-id 464CAE24.9020306@g2switchworks.com
Whole thread Raw
In response to UNION help  ("Robert James" <srobertjames@gmail.com>)
List pgsql-general
Robert James wrote:
> Is there anyway to tell if the records in a union came from the 1st
> query or the second?
> Can I modify the individual queries to let me know this?
You can do something like:

select 'set1' as identifier, field1, field2 from table1
union
select 'set2', field1, field2 from table2

pgsql-general by date:

Previous
From: Ben
Date:
Subject: Re: Installing contrib / fuzzystr
Next
From: Glen Parker
Date:
Subject: Re: Vacuum non-clustered tables only