DB Link
API Reference Guide
Product Documentation:

Visualization DB Link
Documentation Home
List of all members | Public Member Functions
IldDiagnostic Class Reference

Instances of the class IldDiagnostic are used to store the context in which an error or a warning was raised. More...

#include <ildblink/ilderr.h>

Public Member Functions

IlInt getCode () const
 Get the error code. More...
 
const char * getConnection () const
 Get the connection string. More...
 
IldFuncId getFunctionCode () const
 Get the function code. More...
 
const char * getMessage () const
 Get the error message. More...
 
const char * getName () const
 Get the name of the object in error. More...
 
IlInt getNativeCode () const
 Get the native error code. More...
 
IldErrorOrigin getOrigin () const
 Get the origin of the error. More...
 
const char * getSqlstate () const
 Get the SQL state. More...
 

Detailed Description

Instances of the class IldDiagnostic are used to store the context in which an error or a warning was raised.

Library: dbkernel

See also
IldErrorOrigin

Member Function Documentation

◆ getCode()

IlInt IldDiagnostic::getCode ( ) const

Get the error code.

Returns
The numeric code of the error.
Warning
Confusion could arise between an error code issued by the server and an error code from the DB Link API. To distinguish the origin of the error, you can compare the values of the code and native code, or you can check for the originator of the error using the getOrigin member function. When code and native code are equal, the error orignates from the RDBMS client native library.

◆ getConnection()

const char * IldDiagnostic::getConnection ( ) const

Get the connection string.

Returns
The faulty authentication string when one exists.

◆ getFunctionCode()

IldFuncId IldDiagnostic::getFunctionCode ( ) const

Get the function code.

Returns
The symbolic function code associated with the function where the error was raised.

The possible codes are values of the IldFuncId enumeration.

◆ getMessage()

const char * IldDiagnostic::getMessage ( ) const

Get the error message.

Returns
The text of the message associated with the error.

◆ getName()

const char * IldDiagnostic::getName ( ) const

Get the name of the object in error.

Returns
The name of the object for which the error was raised.

If it is not applicable, it returns a null pointer.

◆ getNativeCode()

IlInt IldDiagnostic::getNativeCode ( ) const

Get the native error code.

Returns
The native error code.

If the error was raised by the Rogue Wave Views DBLink API, it returns 0.

◆ getOrigin()

IldErrorOrigin IldDiagnostic::getOrigin ( ) const

Get the origin of the error.

Returns
The code corresponding to the layer in which the error originated.

◆ getSqlstate()

const char * IldDiagnostic::getSqlstate ( ) const

Get the SQL state.

Returns
The SQLSTATE string corresponding to the error.