![]() Chapter Contents |
![]() Previous |
![]() Next |
| SAS/ACCESS Interface to IMS-DL/I Software |
The following two Fast Path database types are supported by the IMS-DL/I DATA step interface by using a BMP region:
Standard DL/I database calls can be used with a PCB that references an MSDB or DEDB to access database segments. Two additional calls are available:
The IMS-DL/I DATA step interface supports the FLD and POS calls from a BMP region.
| FLD Call |
Like any DL/I call, the FLD call returns a status code. In addition, DL/I returns abnormal status information for each FSA in the call. If a non-blank status code is returned from a FLD call, it may be necessary to examine the contents of the FSA return codes. The DL/I INFILE statement option FSARC= specifies a 200-byte character variable to which the first 200 FSA status code bytes can be returned.
The following example issues a FLD call against an MSDB called INVNTORY:
ssa1='PRODUCT (PRODUCT = LOCKS )';
infile msdbpsb dli call=cfunc dbname=database
ssa=ssa1 fsarc=fsa_rc;
file msdbpsb dli;
cfunc = 'FLD ';
database = 'INVNTORY';
put @1 'QUANTITY H100*QUANTITY -100*ORDERS +1 ';
The call accesses a segment called PRODUCT containing data on locks. The FLD call performs these functions:
If the QUANTITY field value is not greater than 100 when the FLD call is executed, the return code for the first FSA contains a D. The following statements check for errors in the call and print an appropriate message on the SAS log for this error:
if _error_ then do;
file log;
if substr(fsa_rc,1,1) = 'D'
then put / '*** Quantity of Product Locks Less
Than 100 ***';
put _all_;
_error_=0;
end;
| POS Call |
The POS call is used with a DEDB to perform one of the following:
In an IMS-DL/I DATA step program, the POS call is issued with a DL/I INPUT statement and a DB PCB. After a POS call is issued, the input buffer is formatted with the requested data as explained in the IBM publication IMS/ESA: Application Programming: EXEC DLI Commands for CICS and IMS.
The SAS statements below execute a POS call for a DEDB called ORDERS:
retain ssa1 'PRODUCT (PRODUCT = LOCKS )';
infile dedbpsb dli call=cfunc dbname=database
ssa=ssa1;
cfunc = 'POS ';
database = 'ORDERS ';
input @3 areaname $char8.
@11 cycl_cnt $pib4.
@15 vsam_rba $pib4.;
The call obtains the position of the last inserted ORDRITEM sequential dependent segment for the locks PRODUCT segment.
![]() Chapter Contents |
![]() Previous |
![]() Next |
![]() Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.