Date: Tue, 20 Jan 2004 12:51:49 -0500
Reply-To: Peter Flom <flom@NDRI.ORG>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Peter Flom <flom@NDRI.ORG>
Subject: Re: MERGE confusion and disbelief
Content-Type: text/plain; charset=US-ASCII
You can, indeed, merge multiple datasets at once. SAS doesn't mouth
off because there's nothing for it to mouth off about. Of course, that
doesn't mean that this code does what you WANT it to do, but that's
another matter altogether.
HTH, and glad there was a (nonstatistical) question I could answer here
Peter
Peter L. Flom, PhD
Assistant Director, Statistics and Data Analysis Core
Center for Drug Use and HIV Research
National Development and Research Institutes
71 W. 23rd St
www.peterflom.com
New York, NY 10010
(212) 845-4485 (voice)
(917) 438-0894 (fax)
>>> "Cacialli, Doug" <Doug_Cacialli@URMC.ROCHESTER.EDU> 1/20/2004
12:38:46 PM >>>
Y'all,
I'm rewriting some non-functioning (or malfunctioning?) code written by
a
researcher in my department. In the midst of doing this, I came
across:
DATA NANA;
MERGE B0 W1 W2 W3 W4 W5 W5 W6 W7;
BY PATID DRUG;
RUN;
SAS doesn't mouth-off ... it seems to be okay with this. I would've
never
attempted this, as I am under the impression that you can't merge more
than
two sets in one data step. This has been my impression since I
started
using SAS 2.5 years ago.
Have I been living a lie? Can you merge multiple (i.e., more than two)
data
sets in one statement like this, or is the result the merge of the
first
two? And if that's the case, why isn't SAS all pissed off that I'm
submitting crappy code?! Thanks for the help.
Doug out.
-------------------------------------------
Doug Cacialli - Data Manager / Data Analyst
Depression Research Laboratory
University of Rochester Medical Center
300 Crittenden Boulevard - Box PSYCH
Rochester, New York 14642
Phone: (585)273-3309 Fax: (585)506-0287
-------------------------------------------