The open statement substitutes any input variables in the statement buffer, and sends the result to Adaptive Server for execution. The syntax for the open statement is:
exec sql [at connection_name] open cursor_name [using {host_var_list | sql descriptor descriptor_name | descriptor sqlda_name}];
where:
cursor_name is the name given to the cursor in the declare statement.
host_var_list consists of the names of the host variables that contain the values for dynamic parameter markers.
descriptor_name is the name of the descriptor that contains the value for the dynamic parameter markers.
sqlda_name is the name of the SQLDA.