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 (January 2002, week 1)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Thu, 3 Jan 2002 18:38:18 -0500
Reply-To:   Sigurd Hermansen <hermans1@WESTAT.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   Sigurd Hermansen <hermans1@WESTAT.COM>
Subject:   Re: Implicit merge on PROC
Comments:   To: Robert Abelson <rabelson@KAI-RESEARCH.COM>

For the best of both worlds, try

proc sql; create view setvw as select * from set1,set2 .... ....; quit; proc print data=setvw; run;

Sig

On Thu, 3 Jan 2002 18:33:05 -0500, Robert Abelson <rabelson@KAI- RESEARCH.COM> wrote:

>Mike, > >You can print the result of a merge of two datasets using PROC SQL. > >proc sql; > select * > from set1, set2 > where set1.id = set2.id; >quit; > >This will print, but it will probably not look so great. > >Bob Abelson >KAI >6001 Montrose Rd. >Suite 920 >Rockville, MD 20852 >T: 301-770-2730 >F: 301-770-4183 >rabelson@kai-research.com > > >> -----Original Message----- >> From: Kemp, Michael [SMTP:Michael.Kemp@GS.COM] >> Sent: Thursday, January 03, 2002 6:24 PM >> To: SAS-L@LISTSERV.UGA.EDU >> Subject: Implicit merge on PROC >> >> Is it possible to merge two (or more datasets) using a PROC statement? >> >> For example, >> If you want to do a proc print on two separate datasets, must you always >> run >> a data step prior to the PROC that merges the data, and then run the PROC >> against the resultant dataset? Or, is there a way to do something with the >> effect of: >> >> PROC PRINT DATA=SET1 MERGE SET2 BY ID; >> RUN; >> >> If this were possible, it would seem to me to be much more efficient. >> >> Thanking you in advance. >> >> Mike Kemp


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