AdsPrepareSQL

Advantage Client Engine

Prepares an SQL statement for execution

Syntax

UNSIGNED32

AdsPrepareSQL( ADSHANDLE hStatement,

UNSIGNED8 *pucSQL )

Parameters

hStatement (I)

Handle of an SQL statement created by a call to AdsCreateSQLStatement.

pucSQL (I)

The SQL statement given as a null terminated string.

Remarks

Use AdsPrepareSQL when executing SQL statements that contain parameters.

The Advantage Client Engine supports named parameters as well as unnamed parameters. An unnamed parameter is represented with a question mark (?). Named parameters are represented with a string preceded by a colon. The "String" portion may contain the characters ‘0..9’, ‘A..Z’, ‘a..z’, or the underscore character (‘_’). Any sub-string in the SQL statement that meets the following criteria will be assumed to be a named parameter: