Examples of Data Transfer Services (DTS) |
Purpose |
You can use the INLIB= and OUTLIB= options with PROC UPLOAD or PROC DOWNLOAD to transfer multiple SAS files in a single step. This capability enables you to transfer an entire library or selected members of a library.
Note: The INLIB= option must be used with the OUTLIB= option.
You can specify which member types to transfer by using the MEMTYPE= option in one of the following statements:
If you use the MEMTYPE= option in the SELECT or the EXCLUDE statement, you can specify only one value. If you use the MEMTYPE= option in the PROC UPLOAD or the PROC DOWNLOAD statement, you can specify a list of MEMTYPE values enclosed in parenthesis.
Here are the valid values for the MEMTYPE= option:
Programs |
Example 9.1: Using the INLIB= Option in the PROC DOWNLOAD Statement |
This example downloads all SAS data sets, catalog files, SQL views, and MDDB files in the library WORK on the server and stores them in the library WORK on the client:
proc download inlib=work outlib=work; run;
Example 9.2: Using the MEMTYPE= Option in the PROC UPLOAD Statement |
This example uploads all MDDB and FDB files that are in the library THIS on the client and stores them in the library THAT on the server:
proc upload inlib=this outlib=that memtype=(mddb view); run;
Example 9.3: Using the MEMTYPE= Option in the SELECT Statement |
This example downloads the MDDB files TEST1 and TEST2 and the SAS data set TEST3 that are in the library WORK on the server and stores them in the library LOCAL on the client:
proc download inlib=work outlib=local; select test1 test2 test3(mt=data)/memtype=mddb; run;
Example 9.4: Using the MEMTYPE= Option in the EXCLUDE Statement |
This example uploads all SAS data sets, catalog files, MDDB files, FDB files, and SQL views that are in the library LOCAL on the client, except the SQL views A1, A2, A3. If then stores them in the library REMOTE on the server:
proc upload inlib=local outlib=remote memtype=all; exclude a1-a3/memtype=view; run;
Copyright © 2008 by SAS Institute Inc., Cary, NC, USA. All rights reserved.