A number of sample programs are provided to demonstrate the usage of the user exit function for a different device or software interface. The program listings identify the version of the device support software used.
You may modify or otherwise use these programs in any way you wish. Comments within these sample programs provide technical information for writing your own user exit programs.
The following topics provide information about the sample programs related to your operating system:
The user exit sample programs for DB2 for OS/2 are found in the instance subdirectory of the \sqllib\samples\rexx directory. The last user exit sample program (dbuexit.CAD) is an exception: it is found in the instance subdirectory of the \sqllib\samples\c directory. The sample you choose to implement should be renamed with the executable file name of db2uexit with an extension of either .cmd or .exe. This renamed file should be placed in the \sqllib\bin directory for use as a user exit program.
While the samples provided are mostly REXX command files, your user exit program can be written in a different programming language. The executable file name must be db2uexit with an extension of either .cmd or .exe.
There are five OS/2 sample programs provided:
|Note:||Only Version 2.2 of the Sytos Premium product is currently supported. You require the OS/2 FixPack 26 to use this product.|
Review the sample program listing to determine requirements such as predefining procedures.
A unique volume label is assigned to each backup copy of a database so that multiple backups of the same database or different databases can be stored on the same tape. When a database is being restored, this program selects the most recent backup copy. This feature can be bypassed by modifying the backup log file.
MaynStream does not support redirecting the restored database to a drive other than the one on which the database was backed up.
This program uses the OS/2 XCOPY command. The storage device can be any device supported by OS/2, such as a fixed disk, diskette, or optical cartridge. These devices can be LAN redirected drives if the workstation is set up to support redirected drives.
XCOPY cannot be used for backing up and restoring databases.
This C program is equivalent to the ADSTAR Distributed Storage Manager (ADSM) sample program to archive and retrieve database logfiles as presented in the sample programs for UNIX-based operating systems.
The userexit configuration parameter causes the database manager to call a user exit program for archiving and retrieving logs. There are three IBM-supplied sample user exit programs on UNIX platforms: one for disk, one for tape, and one for ADSM. It is not mandatory that you use these programs. You may choose to create your own user exit programs. The sample programs may provide you with a model or suggestions that you can use when creating your user exit programs. Useful information is found in the header information in each sample program.
While the samples provided are coded in the C language, your user exit program can be written in a different programming language. The user exit program must be an executable file whose name is db2uext2.
There are three UNIX-based operating system sample programs provided:
[ DB2 List of Books | Search the DB2 Books ]