SQLSetParameter - cBaseSQLExecutor

Sets a parameter for a parameterized query

Type: Procedure

Parameters: String sParamName Variant vValue

ParameterDescription
sParamNameParameter Name
vValueParameter Value


Syntax
Procedure SQLSetParameter String sParamName Variant vValue

Call: Send SQLSetParameter sParamName vValue


Description

SQLSetParameter sets a parameter for a parameterized query.

Call SQLParameterInfo to retrieve the full set of parameters.

Example

String[][] aStrings

// Prepare the query
Send SQLPrepare of ghoSQLExecutor @SQL"SELECT
    Name,  
    City,
    Zip FROM Customer
    WHERE City = ${City}"

// Test for errors
If (not(Err)) Begin
    // Set the parameter value
    Send SQLSetParameter of ghoSQLExecutor "City" "Miami"

    // Get the result set
    Get SQLExecute of ghoSQLExecutor to aStrings

    // Process results here..
End