skip to main content
Interface Provider API : Reference : OAIP_nativeW (Unicode version)
 

OAIP_nativeW (Unicode version)

int OAIP_nativeW(
    IP_HDBC hdbc,
    DAM_HSTMT hstmt,
    int iCommandOption,
    OAWCHAR * wsCommand,
    int64 * piNumResRows)
Table 20. Parameters for OAIP_nativeW
Parameter
Type
Description
IN
hdbc
IP_HDBC
The connection handle as defined by the IP.
hstmt
DAM_HSTMT
The statement handle of the currently active statement.
iCommandOption
int
DAM_NC_VALIDATE - Validate the passed-in command.
DAM_NC_EXECUTE - Execute the native command and return the number of rows affected.
wsCommand
OAWCHAR *
The command to execute.
OUT
piNumResRows
int64 *
The number of rows affected by this operation.
RETURN
int
DAM_SUCCESS - In DAM_NC_VALIDATE mode, this indicates that the command is supported. In DAM_NC_EXECUTE mode this indicates that the command was successfully executed.
DAM_FAILURE - Indicates there is a syntax error in the native command. The specific error message should be added using the dam_addError/dam_addErrorW function.
DAM_NOT_AVAILABLE - In DAM_NC_VALIDATE mode, the command issued is not supported.
From this function you can use dam_setIP_hstmt to save any context it creates during validation and use dam_getIP_hstmt to retrieve the context when called for DAM_NC_EXECUTE.

See also

*dam_addError/dam_addErrorW
*dam_setIP_hstmt
*dam_getIP_hstmt