This example creates
an access descriptor and a view descriptor that are based on DB2 data.
options linesize=80;
libname adlib 'SAS-library';
libname vlib 'SAS-library';
proc access dbms=db2;
/* create access descriptor */
create adlib.customr.access;
table=testid.customers;
ssid=db2;
assign=yes;
rename customer=custnum;
format firstorder date7.;
list all;
/* create vlib.usacust view */
create vlib.usacust.view;
select customer state zipcode name
firstorder;
subset where customer like '1%';
run;
This next example uses
the SERVER= statement to access the SQL/DS table Testid.Orders from
a remote location. Access and view descriptors are then created based
on the table.
libname adlib 'SAS-library';
libname vlib 'SAS-library';
proc access dbms=db2;
create adlib.customr.access;
table=testid.orders;
server=testserver;
assign=yes;
list all;
create vlib.allord.view;
select ordernum stocknum shipto dateorderd;
subset where stocknum = 1279;
run;