Subject Re: [firebird-support] insert into select ... union ...
Author unordained
insert into temp_hl7_export_people (person_id)
select temp_hl7_export_tasks.person_id from temp_hl7_export_tasks
select temp_hl7_export_pharm.person_id from temp_hl7_export_pharm
select from people where person_id != 0 and last_update_stamp >

I get 'token unknown: union' at the first one. I can run any chunk of this just fine. I'm using
this to then join back against various tables during an export (multiple parallel datasets,) so I'd
really rather the temp_hl7_export_people table be entirely unique before I start doing that, to
avoid working the engine harder than needed. (The two first temp tables have their own logic
applied ahead of time.) The field types match, number of fields match ... thus my question about
unions during 'insert into'.

Thanks Helen,

---------- Original Message -----------
From: Helen Borrie <helebor@...>
> I'm still trying to figure out what you're doing here...trying to load the
> output from a union select into another table, I think...
> If you just want a "distinct" union set to work with, omit the ALL
> keyword. The default behaviour is to exclude duplicate rows.
> ./heLen
------- End of Original Message -------