The routine may be
used to promote a locator
to become a “primary” locator, to demote it to become a “secondary”
locator, or to enquire about the primary/secondary
status of a locator. It allows control
over the duration for which an HDS container file remains open; each file remains open
only so long as there is at least one primary locator associated with it.
DAT_PRMRY( SET, LOC, PRMRY, STATUS )
SET = LOGICAL (Given)
.TRUE. value is given for this argument, then the routine will perform a “set” operation
to set the primary/secondary status of a locator. Otherwise it will perform an “enquire”
operation to return the value of this status without changing it.
LOC = CHARACTER
DAT__SZLOC ) (Given and Returned)
The locator whose primary/secondary status is to be set or
PRMRY = LOGICAL (Given and Returned)
If SET is .TRUE., then this is an input
argument and specifies the new value to be set (.TRUE. for a primary locator, .FALSE. for a secondary
locator). If SET is .FALSE., then this is an output argument and will return a value indicating whether
or not a primary locator was supplied.
STATUS = INTEGER (Given and Returned)
The value of the LOC argument will not normally be changed. However, if it is the last
primary locator associated with a container file, and is being demoted from a primary to a
secondary locator, then the container file will be left without an associated primary locator. In
this case, the locator supplied will be annulled (along with any other secondary locators
associated with the same file), a value of DAT__NOLOC will be returned, and the file will be
The DAT__NOLOC constant is defined in the include file DAT_PAR.
Copyright © 2019 East Asian Observatory