O'Reilly logo

SAS 9.4 Language Reference, 6th Edition by SAS Institute

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

.SASXREG file
a text file with the file extension .SASXREG that contains the text representation of
the actual binary SAS Registry file.
Managing the SAS Registry
Primary Concerns about Managing the SAS Registry
CAUTION:
If you make a mistake when you edit the registry, your system might become
unstable or unusable. Whenever possible, use the administrative tools, such as the
New Library window, the PRTDEF procedure, Universal Print windows, and the
Explorer Options window, to make configuration changes, rather than editing the
registry. This is to ensure that values are stored properly in the registry when
changing the configuration.
CAUTION:
If you use the Registry Editor to change values, you are not warned if any entry
is incorrect. Incorrect entries can cause errors, and can even prevent you from
starting a SAS session.
Backing Up the Sasuser Registry
Why Back Up the Sasuser Registry?
The Sasuser
1
part of the registry contains personal settings. It is a good idea to back up
the Sasuser part of the registry if you have made substantial customizations to your SAS
session. Substantial customizations include the following:
installing new printers
modifying printer settings from the default printer settings that your system
administrator provides for you
changing localization settings
altering translation tables with TRANTAB
When SAS Resets to the Default Settings
When SAS starts up, it automatically scans the registry file. SAS restores the registry to
its original settings under two conditions:
If SAS detects that the registry is corrupt, then SAS rebuilds the file.
If you delete the registry file called regstry.sas7bitm, which is located in the Sasuser
library, then SAS restores the Sasuser registry to its default settings.
CAUTION:
Do not delete the registry file that is located in Sashelp; this prevents SAS
from starting.
1
The Sashelp part of the registry contains settings that are common to all users at your site. Sashelp is Write protected, and can be
updated only by a system administrator.
224 Chapter 14 The SAS Registry
Ways to Back Up the Registry
There are two methods for backing up the registry and each achieves different results:
Method 1: Save a copy of the Sasuser registry file called regstry.sas7bitm.
The result is an exact copy of the registry at the moment that you copied it. If you
need to use that copy of the registry to restore a broken copy of the registry, then any
changes to the registry after the copy date are lost. However, it is probably better to
have this backup file than to revert to the original default registry.
Method 2: Use the Registry Editor or PROC REGISTRY to back up the parts of the
Sasuser registry that have changed.
The result is a concatenated copy of the registry, which can be restored from the
backup file. When you create the backup file using the EXPORT= statement in
PROC REGISTRY, or by using the Export Registry File utility in the Registry
Editor, SAS saves any portions of the registry that have been changed. When SAS
restores this backup file to the registry, the backup file is concatenated with the
current registry in the following way:
Any completely new keys, subkeys, or values that were added to the Sasuser
registry after the backup date are retained in the new registry.
Any existing keys, subkeys, or values that were changed after SAS was initially
installed, then changed again after the backup, are overwritten and revert to the
backup file values after the restore.
Any existing keys or subkeys (or values that retain the original default values)
will have the default values after the restore.
Using the Explorer to Back Up the SAS Registry
To use the Explorer to back up the SAS Registry:
1. Start SAS Explorer with the EXPLORER command, or select View ð Explorer.
2. Select Tools ð Options ð Explorer.
The Explorer Options window appears.
3. Select the Members tab.
4. Select ITEMSTOR in the Type list.
5. Click Unhide.
If ITEMSTOR does not have an icon associated with it in the Type list, you are
prompted to select an icon.
6. Open the Sasuser library in the Explorer window.
7. Right-click the Regstry.Itemstor file.
8. Select Copy from the pop-up menu and copy the Regstry file. SAS names the file
Regstry_copy.
Operating Environment Information
You can also use a copy command from your operating environment to make a
copy of your registry file for backup purposes. When viewed from outside SAS
Explorer, the filename is regstry.sas7bitm. Under z/OS, you cannot use the
environment copy command to copy your registry file unless your Sasuser library
is assigned to an HFS directory.
Managing the SAS Registry 225

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required