| Contents: | Main | Chapter | See Also: | Getting Started Manual | Advanced User Manual | |||
All DBS calls use parameter passing instead of relying on variables set prior to the call that are passed through the symbol table. However, VA FileMan's key variables (e.g., DUZ and DT) are not passed in the parameter list. When needed, VA FileMan continues to expect them to be defined in the local symbol table.
Except where noted, the order of the parameters in the argument list follows a consistent pattern as follows:
Figure 90: Database Server (DBS) API—Format and Conventions of the Calls: Order of the Parameters in the Argument List
TAG^ROUTINE(file,iens,field,flags,other_required_params,other_optional_params)
If a particular call does not use one or more of the first four parameters, that parameter is omitted from the list of arguments. Generally, when a file is needed, the file number (not global root) must be passed. This allows for consistency when referring either to a top-level file or to a subfile. Similarly, a field is identified by its field number.
When it is necessary to pass the root of a local or global array, the complete closed reference of the array for use with subscript indirection is needed, not the traditional open VA FileMan root. Examples are illustrated in Table 35:
Table 35: Database Server (DBS) API—Format and Conventions of the Calls—Acceptable vs. Unacceptable Roots
| Acceptable Roots | Unacceptable Roots |
| ^TMP("NMSP",$J) | ^TMP("NMSP",$J, |
| LOCALVAR | LOCALVAR( |
Since the array identified by this root is accessed by indirection, the contents of the array can be changed by the VA FileMan call. The description of the individual calls indicates whether you can rely on the arrays not being changed. In addition, to assure that an input array is not inadvertently changed during the DBS call, namespace the array.
Reviewed/Updated: May 2026