LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (December 2000, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Fri, 8 Dec 2000 15:16:48 -0500
Reply-To:     "Fehd, Ronald J." <rjf2@CDC.GOV>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         "Fehd, Ronald J." <rjf2@CDC.GOV>
Subject:      Re: Further Clarification of Merge Maybe
Comments: To: "Schulthess, Rebecca" <schulthr@MMRF.MFLDCLIN.EDU>
Content-Type: text/plain; charset="iso-8859-1"

you need the in= data set option:

DATA MERGED; merge A(in = HaveA) B; by Q; if HaveA;

Ron Fehd the macro maven CDC Atlanta GA USA RJF2@cdc.gov OpSys: WinNT Ver: 8.1 ---> cheerful provider of UNTESTED SAS code!*! <---

> -----Original Message----- > From: Schulthess, Rebecca [mailto:schulthr@MMRF.MFLDCLIN.EDU] > Sent: Friday, December 08, 2000 3:13 PM > To: SAS-L@LISTSERV.UGA.EDU > Subject: Further Clarification of Merge Maybe > > > Data set A has about 300 observations and Data set B has > around 5000. All I > want is the "added" information from B for the 300 in A. > > > I have two data sets, A and B. A has the following > variables: e,f,g,q. B > has the following variables: x,y,z,w,d,q. Notice q is common > to both data > sets (it will hold the same value in both data sets too). I > want to have > the observations in A have the variables (and values) of B. > How can I do > this? > > Example: Data set A: Joe Blowe Doctor 34 > Data set B: Marshfield WI 54449 Peds GR4 34 > GOAL: Joe Blowe Doctor 34 Marshfield WI > 54449 Peds GR4 > > Becky Schulthess > Statistical Data Analyst > Marshfield Epidemiology Research Center > x93757 >


Back to: Top of message | Previous page | Main SAS-L page