Date: Tue, 17 Nov 2009 05:40:34 -0800
Reply-To: AlexG <algomlop@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: AlexG <algomlop@GMAIL.COM>
Organization: http://groups.google.com
Subject: proc sql and simple indexes
Content-Type: text/plain; charset=ISO-8859-1
hi, I've 2 simple data sets. if I execute a join using proc sql, it
seems that the index isn't used.
if I execute a MERGE, the index is used ( "INFO: Index i selected for
BY clause processing"). Example:
options msglevel=I;
data one;
i=1;
a='a';
run;
proc sql;
create unique index i on one;
quit;
data two;
i=1;
b='b';
run;
proc sql;
create unique index i on two;
quit;
proc sql;
create table joined as
select b from one, two where one.i=two.i;
quit;
/*log prints: INFO: Index i selected for BY clause processing.*/
data joined2;
merge one two;
by i;
run;
thx!