The GIS Procedure

MOVE Statement

Moves a SAS/GIS catalog entry or data set.

Notes: You can move a single GIS entry or include the dependent entries and data sets that are referenced by the source.
The MOVE statement deletes the original entry or data set and creates a new copy in the target directory. If you do not have Write permission to the source location, MOVE leaves the original entry or data set in its directory and creates a copy in the target directory.

Syntax

MOVE <libref.catalog.>entry-name<.type> </ options>;

Summary of Optional Arguments

ALIAS=(old-libref-1=new-libref-1<, ..., old-libref-n=new-libref-n>)

specifies libref translations.

BLANK

specifies that internal pathnames should be cleared in the moved entries.

CHECKPARENT

specifies that data sets and catalog entries are checked before they are moved to see what other GIS entries references them.

DESTCAT=libref.catalog

specifies the destination for the moved catalog entries.

DESTLIB=libref

specifies the destination library for the moved data sets.

ENTRYTYPE=type

specifies the type of GIS catalog entry to move.

REPLACE

specifies that both existing catalog entries and data sets that have the same name as moved entries and data sets should be overwritten.

SELECT=_ALL_ | ENTRY | DATASETS | SPATIAL | LABEL | OTHER | NOSOURCE

specifies which data sets or catalog entries that are referenced by the source entry should be moved.

Required Argument

<libref.catalog.>entry<.type>

specifies the catalog entry to move. If you specify a one-level name, the current catalog is used.

Note When you specify a four-level entry name, type must be the actual SAS/GIS catalog entry extension (for example, GISMAP, not MAP).

Options

Separate the list of options from the catalog entry name with a slash (/).

ALIAS=(old-libref-1=new-libref-1<, ..., old-libref-n=new-libref-n>)

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 moved entry.

BLANK

specifies that internal pathnames should be cleared in the moved entries.

CHECKPARENT

specifies that data sets and catalog entries are checked before they are moved to see what other GIS entries references them. If any references are found, the catalogs and data sets are copied instead of being moved.

If CHECKPARENT is not specified, data sets and catalog entries are moved without checking for references, which might cause problems with other GIS entries.

Default CHECKPARENT
CAUTION:
Do not use host commands to move or rename SAS data sets that are referenced in GISSPA entries.
Moving or renaming a data set that is referred to in a spatial entry breaks the association between the spatial entry and the data set. To prevent breaking the association, use the PROC GIS MOVE statement with the CHECKPARENT option instead of a host command.

DESTCAT=libref.catalog

specifies the destination for the moved catalog entries. If the libref value is omitted, WORK is used as the default. Entries are moved to the WORK.catalog. If DESTCAT= is omitted, then the libref value defaults to WORK and the catalog value defaults to the catalog name of the source being moved. For example, if you are moving either MAPS.USA.STATE or MAPSSASUSA.STATE, and you omit DESTCAT=, the data set that you are moving is written to WORK.USA.STATE.

DESTLIB=libref

specifies the destination library for the moved data sets. If DESTLIB= is omitted, the default libref is WORK.

ENTRYTYPE=type

specifies the type of GIS catalog entry to move. The following are the values for type:

  • GISSPA or SPATIAL
  • GISMAP or MAP
  • GISLAYER or LAYER
  • GISCOVER or COVERAGE

This argument can be omitted if a complete, four-level entry name is specified. The following statements are identical:

move maps.usa.state entrytype=map

move maps.usa.state.gismap

REPLACE

specifies that both existing catalog entries and data sets that have the same name as moved entries and data sets should be overwritten.

SELECT=_ALL_ | ENTRY | DATASETS | SPATIAL | LABEL | OTHER | NOSOURCE

specifies which data sets or catalog entries that are referenced by the source entry should be moved. The following are the values for this argument:

_ALL_

moves all dependent catalog entries and data sets. Equivalent to specifying both ENTRY and DATA.

DATA

moves all dependent data sets. It is equivalent to specifying SPATIAL, LABEL, and OTHER.

ENTRY

moves all dependent catalog entries.

LABEL

moves dependent label data sets.

NOSOURCE

moves entry dependents as specified, but does not move the specified source entry.

OTHER

moves other dependent data sets (besides spatial and label data sets), such as linked attribute data sets.

SPATIAL

moves dependent spatial data sets.

Details

You can use PROC COPY or another utility to move a SAS/GIS catalog entry or data set. However, 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.