Returns an error code when a database error occurs in dwcontrol. Error codes -1 through -4 are PowerBuilder codes. Other codes are database-specific. Returns 0 if there is no error.
If dwcontrol is null, the method returns null.
PowerBuilder error codes are:
?-1 Can't connect to the database because of missing values in the transaction object.
?-2 Can't connect to the database.
?-3 The key specified in an Update or Retrieve no longer matches an existing row. (This can happen when another user has changed the row after you retrieved it.)
?-4 Writing a blob to the database failed.