| The GIS Procedure |
| COPY <libref.catalog.>entry<.type> </ options> ; |
| Description |
COPY copies a SAS/GIS catalog entry or data set. You can copy a single GIS entry or include the dependent entries and data sets that are referenced by the source.
When you use the COPY statement, you must specify the catalog entry for the source entry you want to copy. If you specify a one-level name, the current catalog is used.
Note: When you specify a four-level entry name,
the type must be the actual SAS/GIS catalog
entry extension, for example, GISMAP instead of MAP. ![[cautionend]](../../../../common/61925/HTML/default/images/cautend.gif)
Note: If you use PROC COPY or another utility to copy a SAS/GIS catalog
entry or data set, you might receive warnings in your SAS log that the paths
are not the same. If you receive a message that the paths are not the same,
you can use the SYNC statement to reset the paths. See SYNC Statement for more information. ![[cautionend]](../../../../common/61925/HTML/default/images/cautend.gif)
| COPY Statement Optional Arguments |
ALIAS=(old-libref-1=new-libref-1 <, ... ,old-libref-n=new-libref-n>)
SELECT= _ALL_ | ENTRY | DATASETS | LABEL | OTHER | NOSOURCE | SPATIAL
The following sections contain descriptions of additional COPY statement arguments.
| ALIAS=(old-libref-1=new-libref-1 <, ... ,old-libref-n=new-libref-n>) |
ALIAS= specifies libref translations. The old-libref value is the libref that is stored in the existing catalog entry. The new-libref value is the libref that you want to substitute in the new copy of the entry.
| BLANK |
BLANK specifies that internal pathnames should be cleared in the copied entries.
| DESTCAT=libref.catalog |
DESTCAT= specifies the destination for the copied catalog entries.
If libref is omitted, WORK is used as the default. Entries are copied to WORK.catalog. If DESTCAT= is omitted, libref defaults to WORK and the catalog to the catalog name of the source being copied. For example, if you are copying MAPS.USA.STATE, and you omit DESTCAT=, the copy of the data set is written to WORK.USA.STATE.
| DESTLIB=libref |
DESTLIB= specifies the destination library for the copied data sets.
If DESTLIB= is omitted, the default libref is WORK.
| ENTRYTYPE=type |
ENTRYTYPE= specifies the type of GIS catalog entry to copy. The following are the values for type:
This argument can be omitted if a complete, four-level entry name is specified. The following statement are identical:
Note: When you specify four-level
entry names, type must be the actual SAS/GIS catalog
entry extension, for example, GISMAP, not MAP. ![[cautionend]](../../../../common/61925/HTML/default/images/cautend.gif)
| REPLACE |
REPLACE specifies that both existing catalog entries and data sets that have the same name as copied entries and data sets should be overwritten.
| SELECT=_ALL_ | ENTRY | DATASETS | LABEL | OTHER | NOSOURCE | SPATIAL |
SELECT= specifies which data sets or catalog entries that are referenced by the source entry should be copied. The following are the values for this option:
copies all dependent catalog entries and data sets. It is equivalent to specifying both ENTRY and DATA.
copies all dependent data sets. It is equivalent to specifying SPATIAL, LABEL, and OTHER.
copies entry dependents as specified, but does not copy the specified source entry.
copies other dependent data sets (besides spatial and label data sets), such as linked attribute data sets.
Copyright © 2007 by SAS Institute Inc., Cary, NC, USA. All rights reserved.