NET/MASTER Network Control Language (NCL) Programmer's Guide

Opening a UDB or UDB Pair for Access by NCL
Working With Files
106160 Tandem Computers Incorporated 12–25
The following code segment illustrates this for a UDB pair:
INTCLEAR
INTCMD "UDBCTL OPEN=($DATA.SUBVOL.MYFILE1,",
"$DATA.SUBVOL.MYFILE2) ID=UDBID1"
INTREAD
INTCONT
FILE OPEN ID=UDBID1
FILE GET ID=UDBID1
After a UDB or UDB pair is assigned a system-wide UDB ID by the UDBCTL
command, the NCL process uses one FILE OPEN verb to open the UDB or UDB
pair. The FILE OPEN verb uses both the UDBID operand, which specifies the
system-wide UDB ID of the UDB or UDB pair, and the ID operand, which
explicitly assigns an identical local file identifier to the UDB or UDB pair. That is,
the UDBID operand and the ID operand specify the same identifier. This means
that the local file identifier used in the NCL process is the same as the system-wide
UDB ID assigned by the UDBCTL command.
The following code segment illustrates this for a single UDB:
INTCLEAR
INTCMD "UDBCTL OPEN=$DATA.SUBVOL.MYFILE ID=UDBID1"
INTREAD
INTCONT
FILE OPEN UDBID=UDBID1 ID=UDBID1
FILE GET ID=UDBID1
The following code segment illustrates this for a UDB pair:
INTCLEAR
INTCMD "UDBCTL OPEN=($DATA.SUBVOL.MYFILE1,",
"$DATA.SUBVOL.MYFILE2) ID=UDBID1"
INTREAD
INTCONT
FILE OPEN UDBID=UDBID1 ID=UDBID1
FILE GET ID=UDBID1