INT 7B - Btrieve API(Application Program[ming] Interface) The defined set of calls which a program may make to interact with or request services of the operating system or environment under which it is running. Because the inputs and outputs of the calls are well-defined, a program using the API can continue using the identical calls even if the internal organization of the program providing the API changes. (single user) DS:DX -> 38-byte parameter record (see #03840) Return: return code field set Note: Btrieve sets low byte of vector to 33h; this serves as the installation check SeeAlso: INT 2F/AX=AB01h,INT 7F/AX=0200h Format of Btrieve parameter record: Offset Size Description (Table 03840) 00h DWORDDoubleword; four bytes. Commonly used to hold a 32-bit segment:offset or selector:offset address. pointer to data buffer 04h WORD data buffer length 06h DWORDDoubleword; four bytes. Commonly used to hold a 32-bit segment:offset or selector:offset address. pointer to 90-byte record containing positioning info (should be same for all calls for same file) 0Ah DWORDDoubleword; four bytes. Commonly used to hold a 32-bit segment:offset or selector:offset address. pointer to 38-byte FCBsee File Control Block info buffer (should be same for all calls for same file) 0Eh WORD function code (see #03841) 10h DWORDDoubleword; four bytes. Commonly used to hold a 32-bit segment:offset or selector:offset address. pointer to file name/key buffer 14h BYTE key length 15h BYTE key number 16h DWORDDoubleword; four bytes. Commonly used to hold a 32-bit segment:offset or selector:offset address. pointer to status code (see #03842) 1Ah WORD interface code (version specific) 6176h version 5.10 (Table 03841) Values for function code: 00h open 01h close 02h insert 03h update 04h delete 05h get_equal 06h get_next 07h get_prev 08h get_greater 09h get_gr_eql 0Ah get_less 0Bh get_less_eq 0Ch get_first 0Dh get_last 0Eh create 0Fh stat 10h extend 11h set_dir: set directory information 12h get_dir: get directory information 13h begin_trans 14h end_trans 15h abort_trans 16h get_pos: get record position number 17h get_direct: get data by sending record position 18h step_next 19h stop 1Ah version 1Bh unlock 1Ch reset 1Dh set owner 1Eh clear owner 1Fh create supplemental index 20h drop supplemental index 21h step first 22h step last 23h step previous 24h get next extended: get multiple records using a filter 25h get previous extended: get multiple records using a filter 26h step next extended: get multiple records using a filter 27h step previous extended: get multiple records using a filter 28h insert extended: insert one or more records 31h ??? Notes: add 50 (32h) to any "get" operation to just return the key data add 100 (64h) for a single-record wait lock (automatically released on next get) add 200 (C8h) for a single-record nowait lock (nowait lock returns error 54h or 55h if record already locked) add 300 (12Ch) for a multiple-record wait lock (not released until unlock called) add 400 (190h) for a multiple-record nowait lock (nowait lock returns error 54h or 55h if record already locked) (Table 03842) Values for Btrieve status code: 00h successful 01h invalid operation 02h I/O error 03h file not open 04h key value not found 05h duplicate key value 06h invalid key number 07h different key number 08h invalid positioning 09h end of file 0Ah modifiable key value error 0Bh invalid file name 0Ch file not found 0Dh extended file error 0Eh pre-image open error 0Fh pre-image I/O error 10h expansion error 11h close error 12h disk full 13h unrecoverable error 14h record manager inactive 15h key buffer too short 16h data buffer length overrun 17h position block length 18h page size error 19h create I/O error 1Ah number of keys 1Bh invalid key position 1Ch invalid record length 1Dh invalid key length 1Eh not a Btrieve file 1Fh file already extended 20h extended I/O error 22h invalid extension name 23h directory error 24h transaction error 25h transaction is active 26h transaction control file I/O error 27h end/abort transaction error 28h transaction max files 29h operation not allowed 2Ah incomplete accelerated access 2Bh invalid record address 2Ch null key path 2Dh inconsistent key flags 2Eh access to file denied 2Fh maximum open files 30h invalid alternate sequence definition 31h key type error 32h owner already set 33h invalid owner 34h error writing cache 35h invalid interface 36h variable page error 37h autoincrement error 38h incomplete index 39h expanded memory error 3Ah compression buffer too short 3Bh file already exists 3Ch reject count reached 3Dh work space too small 3Eh incorrect descriptor 3Fh invalid extended insert 40h filter limit reached 41h incorrect field offset 4Ah automatic transaction abort 4Dh Btrieve engine busy or resource locked by another user 4Eh deadlock detected 50h conflict 51h lock error 52h lost position 53h read outside transaction 54h record in use 55h file in use 56h file table full 57h handle table full 58h incompatible open mode 5Ah redirected device table full 5Bh server error 5Ch transaction table full 5Dh incompatible lock type 5Eh permission error 5Fh session no longer valid 60h communications environment error 61h data message too small 62h internal transaction error