SQL/MP Installation and Management Guide
Managing Database Applications
HP NonStop SQL/MP Installation and Management Guide—523353-004
10-44
Using SQLCI DUP
Using SQLCI DUP
This example shows using the SQLCI DUP command to move a single SQL program
stored in a Guardian file. After the move, the user requests explicit compilation with
registration in catalog $VOL1.ADMIN:
>> DUP $VOL1.PERSNL.EMPPROG, $VOL1.ADMIN.*,
+> SAVEALL;
>> EXIT;
21> SQLCOMP /IN $VOL1.ADMIN.EMPPROG, OUT $S.#HOLD/
CATALOG $VOL1.ADMIN
If you do not need to recompile your programs, omit the second step.
If you have stored your programs in a separate subvolume, you can use the wild-card
character as the file set list in the DUP command to efficiently duplicate groups of
Guardian programs.
This example shows how to use the wild-card character * (asterisk) to move sets of
programs. The SAVEALL option creates the target file with the same security, owner,
and timestamps as the corresponding source file.
>> DUP $VOL1.PERSNL.*, $VOL1.ADMIN.*,
+> SAVEALL;
The SQLCI DUP command supports the qualified file-set list so that only program files
are identified by the list. This example uses a qualified file-set list to identify and move
a set of programs from a specified catalog:
>> DUP $VOL1.PERSNL.* WHERE SQLPROGRAM,
+> MAP NAMES ($VOL1.PERSNL.* TO $VOL1.ADMIN.*), SAVEALL;
You might store programs in many subvolumes throughout the system. In this case,
you can specify a qualified file-set list to move all the programs from one or many
catalogs; however, you must also include a detailed MAP NAMES and CATALOG
specification to handle all the cases.
If the mapping strategy is complex, you can use other methods for moving programs.
These two examples show two methods of using the DUP command to move these
programs:
$OLD1.PROGS.PROGA1, described in catalog $OLD1.ACCTG
$OLD2.PROGS.PROGA2, described in catalog $OLD1.ACCTG
$OLD3.PROGS.PROGA3, described in catalog $OLD1.ACCTG
$OLD3.PROGS.PROGB3, described in catalog $OLD1.SALES
$OLD1.PROGS.PROGB1, described in catalog $OLD1.SALES
$OLD2.PROGS.PROGB2, described in catalog $OLD1.SALES
$OLD3.PROGS.PROGC3, described in catalog $OLD1.SALES
$OLD2.PROGS.PROGC2, described in catalog $OLD1.SALES
$OLD1.PROGS.PROGC1, described in catalog $OLD1.ORDERS
$OLD1.PROGS.PROGD1, described in catalog $OLD1.ORDERS
$OLD2.PROGS.PROGD2, described in catalog $OLD1.ORDERS
$OLD2.PROGS.PROGE2, described in catalog $OLD1.ORDERS
$OLD3.PROGS.PROGD3, described in catalog $OLD1.ORDERS