Date: Fri, 20 May 2011 11:59:56 -0500
Reply-To: Joe Matise <snoopy369@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Joe Matise <snoopy369@GMAIL.COM>
Subject: Re: Patients who are in either of three tables
Content-Type: text/plain; charset=ISO-8859-1
What output do you need? Just the patient id? Everything?
Something like this would accomplish something like what you want, I would
create table d as
select * from (
select * from a full outer join b
on a.patientid=b.patientid) ab
full outer join c
You can manipulate the select * to get what you need.
On Fri, May 20, 2011 at 11:53 AM, Irin later <email@example.com> wrote:
> I am trying to get patients who are either in table1 or Table 2 or Table3.
> Should be not complicated ...but I am kind of confused at the end of Friday
> as it is a kind of an urgent matter...
> I have patients' id s, flag and program fields.
> How Can I implement it with code? I do not have any duplicats in either
> Could you please help me with that? Thank you in advance,