lastErrCode (Attribute)



Reflects the last error code set by for the ooSQLPackage object.

lastErrCode get: The value of thelastErrCodeattribute will be a SQLite result Result Code Constants or one of the ooSQLite specific result ooSQLite Specific Result Code Constants .
lastErrCode set: The programmer can not set the value of this attribute, it is set internally by the ooSQLite framework.
Remarks: The last error code attribute is similar to the lastErrMsg (Attribute) attribute. Its value is the last status code recorded by ooSQLite. ThelastErrCodeand the lastErrMsgattributes are always updated together. The error message is always the message that goes with the error code.
Example: This example uses thelastErrCodeattribute as part of producing a meaningful error message when anooSQLFunctionobject can not be retrieved from a package:
function = package~getFunction('half')
if function == .nil then do
say 'Failed to get function: half'
say ' Error code: ' package~lastErrCode
say ' Error message:' package~lastErrMsg
return package~lastErrCode
end