Executing a client function with SQLPrepare() and SQLExecute()

You can execute a client function with the SQLPrepare() and SQLExecute() functions.

About this task

To execute a client function with SQLPrepare() and SQLExecute():

Procedure

  1. Prepare the SQL statement for the client function.
  2. Bind the parameters.
  3. Execute the SQL statement.

Results

The following code example illustrates these steps for ifx_lo_open():
rc = SQLPrepare(hstmt, "{? = call ifx_lo_open(?, ?, ?)}", SQL_NTS); 
rc = SQLBindParameter(...); 
rc = SQLExecute(hstmt);