Download IBM 4690 Programming Guide
Transcript
buffadr Address of buffer in which to put data that is read. The key for the record to read must begin at offset zero in this buffer. buffsize Number of bytes to read. The size must equal the record length specified when the file was created. keylen Length of the key string passed in the read buffer. This value must equal the key length specified when the keyed file was created. nbytes Return code. It will contain the number of bytes read if no error occurred. An error code is returned if an error occurred. Refer to the IBM 4690 Store System: Messages Guide for system errors. Write Keyed Record: This operation writes a keyed record in the specified file. | C Interface: | void ADX_CWRITE_KREC(long *nbytes, unsigned int option, unsigned int flags, long fnum, char *bufaddr, long buffsize); | COBOL Interface 77 77 77 77 77 77 NBYTES OPTION FLAGS FNUM BUFFADR BUFFSIZE PIC PIC PIC PIC S9(8) 9(4) 9(4) S9(8) USAGE USAGE USAGE USAGE USAGE USAGE PIC 9(8) IS IS IS IS IS IS COMP-5. COMP-5. COMP-5. COMP-5. POINTER. COMP-5. CALL “ADX_CWRITE_KREC” USING NBYTES, BY VALUE OPTION, BY VALUE FLAGS, BY VALUE FNUM, BY VALUE BUFFADR, BY VALUE BUFFSIZE. Parameters: option bit 0: 0 = Unlock = no 1 = Unlock = yes The record is unlocked after being written. bit 1: 0 = Do not hold the write 1 = Hold the write The hold flag prevents the data from being physically written to a disk file until the next write with hold option is issued by this process. bits 2 to 15: Must be zero flags Not used fnum File number where data is to be written, as returned from a CREATE or an OPEN. buffadr Address of buffer containing data to write. The buffer must contain the desired record’s key at offset 0. buffsize Number of bytes to write. nbytes Return code. It contains the number of bytes written if no error occurred. Notice that a zero (0) return value is a special case for the WRITE with HOLD and is considered a correct value. An error code is returned if an error occurred. Chapter 16. Designing Applications with Other Languages 16-13
Related documents
CodeWarrior™ Development Studio for ColdFire® Architectures v6
8086 Family Utilities User`s Guide for 8080/8085
VPL-PS10/PX10/PX15 Service Manual
Application interface specification for IBM 4610
Motorola MC68306 User`s guide
Tekniques - Textfiles
DNA and PNA Synthesis Instruments and Consumables
CS-1000 User`s Guide
Spectro-X User Manual ver. 4.0 - X