Chapter Contents


SAS/ACCESS Interface to CA-IDMS Software: Reference

Statements Common to All Examples

All of the examples in this chapter contain or generate the following statements:

The $IDMDBUG system option tells the SAS System to write information to the SAS log regarding call parameter values and the formatted calls submitted to CA-IDMS. You can use this information to debug your application and to inspect or verify the DML calls generated by the DATA step interface. Each of the examples in this chapter begin with an OPTIONS statement that specifies the $IDMDBUG option, but these OPTIONS statements are commented out with an asterisk. To execute the OPTIONS statement (and activate the $IDMDBUG system option), remove the asterisk.

The INFILE statements used in these examples specify a subschema and the IDMS keyword, which indicates that the task will be accessing CA-IDMS records. The parameters on the INFILE statements create SAS variables whose values are used to format DML calls and check error status codes after those calls have been issued. None of the parameters have default values and, therefore, each variable must be assigned a valid value or blank before each call. None of the defined variables are included in the output data set. For specific information on each INFILE parameter, see The CA-IDMS INFILE Statement.

A BIND function call must be issued for each record whose data will be retrieved during execution of the DATA step. The BIND RECORD statement establishes addressibility for a named record. In each of these examples, a null INPUT statement issues a BIND RECORD statement for each record (see Using the Null INPUT Statement). After the call is issued, the programs check the status code returned by CA-IDMS to be sure the call was successful. If the call is successful, the DATA step continues. If the call is unsuccessful, execution branches to the STATERR label, error information is written to the SAS log, and the DATA step terminates.

STATERR statements
For each call to CA-IDMS, the examples in this chapter check the status code that is returned by CA-IDMS. When CA-IDMS returns an unexpected status code, these examples execute the statements associated with the STATERR label. These statements

For more information on dealing with status codes, see Checking Call Status Codes.

Chapter Contents



Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.