DQ.GETLASTERROR Function

Returns a string describing the most recent error encountered by a data quality object.

Category: Data Quality
Returned data type: Character
Note: The returned value is a string containing an error message.

Syntax

DQ.GETLASTERROR(<>)

Details

The DQ.GETLASTERROR function is a member of the data quality class. It returns an error message describing the most recent error encountered by a data quality object. The error might have occurred during invocation of any other data quality member function.
A best practice for programmers is to check the result code for each data quality call. If a result code indicates failure, use DQ.GETLASTERROR to retrieve the associated error message.

Example

data quality dq
 integer rc
 string errmsg
dq = dq_initialize()
 rc = dq.loadqkb("XXXXX")
 // an invalid locale name -- this will cause an error
 
 if (rc == 0) then
      errmsg = dq.getlasterror()
 // returns an error message