Xbase DBMS Appendix A

#

Xbase Return Codes

Page Updated 2/19/04

Beginning with release 3.0 exception processing has been removed from the library. There were reports that it was not 100% working, so I trimmed the library back to working code. If there are any volunteers to re-install the exception processing, AND test it, let me know. Thanks - Gary It is generally a good idea to check the method return codes to verify an error hasn't occured. Most Xbase DBMS methods return a SHORT return code value which corresponds to a value in this table.

### Xbase Return Codes

Number | Error | Description | Type
0 | XB_NO_ERROR | Success | General
100 | XB_XBASE_EOF | End of file | Database Index
102 | XB_NO_MEMORY | Error when allocating memory | General
103 | XB_FILE_EXISTS | File Already Exists | Database
104 | XB_OPEN_ERROR | Error when opening file | Database
105 | XB_WRITE_ERROR | Error occured when writing to file | Database Index
106 | XB_UNKNOWN_FIELD_TYPE | Field was not one of: XB_CHAR_FLD XB_FLOAT_FLD XB_NUMERIC_FLD XB_DATE_FLD XB_LOGICAL_FLD or XB_MEMO_FLD | Field
107 | XB_ALREADY_OPEN | Can't open the same file twice | Database Index
108 | XB_NOT_XBASE | Can't open non X-Base file with X-Base routines | Database
109 | XB_INVALID_RECORD | Not a valid record | Database
110 | XB_INVALID_OPTION | Not a valid option | General
112 | XB_SEEK_ERROR | Could not position in file | Database Index
114 | XB_NOT_FOUND | Record for key not found | Index
116 | XB_INVALID_KEY | Invalid key argument given | Index
118 | XB_KEY_NOT_UNIQUE | Trying to add a duplicate key for an unique index | Index
119 | XB_INVALID_KEY_EXPRESSION | An invalid key expression given | Index
121 | XB_INVALID_KEY_TYPE | Invalid Key Type | Index
122 | XB_INVALID_NODE_NO | Internal index error, notify tech support | Index
123 | XB_NODE_FULL | Internal index error, notify tech support | Index
124 | XB_INVALID_FIELDNO | Attempt to access invalid field number | Field
125 | XB_INVALID_DATA | Invalid data encountered | Field
126 | XB_NOT_LEAFNODE | Internal index error, notify tech support | Index
127 | XB_LOCK_FAILED | Lock function failed See errno for detail | Lock
128 | XB_CLOSE_ERROR | Error closing file | Database Index
129 | XB_INVALID_SCHEMA | Error with schema definition, check decimal points | Database
130 | XB_INVALID_NAME | Invalid database name | Memo
131 | XB_INVALID_BLOCK_SIZE | Block size is invalid, must be increment of 512 | Memo
132 | XB_INVALID_BLOCK_NO | Invalid block number used | Memo
133 | XB_NOT_MEMO_FIELD | Not a memo field | Memo
134 | XB_NO_MEMO_DATA | No memo data | Memo
135 | XB_EXP_SYNTAX_ERROR | Expression syntax error | Expression
136 | XB_PARSE_ERROR | Parse error in expression | Expression
137 | XB_NO_DATA | No data for expression | Expression
140 | XB_INVALID_FIELD | Invalid field in expression | Expression
141 | XB_INSUFFICIENT_PARMS | Insufficient paramaters for function | Expression
142 | XB_INVALID_FUNCTION | Invalid function encountered | Expression