Parameter | Description |
---|---|
sSqlQuery | SQL Query |
Procedure SQLPrepare String sSqlQuery
Call: | Send SQLPrepare sSqlQuery |
Prepares a query without executing it.
Prepare a query.
Send SQLPrepare of ghoSQLExecutor @SQL"SELECT Name, City, Zip FROM Customer" // Test for errors If (not(Err)) Begin // Execute the query here.. End
Call SQLExecute to execute a prepared SQL query. SQLExecute can be used in two ways, with or without a result set.
Example of SQLExecute with result set.
String[][] aResults // Fetch results into aResults Get SQLExecDirect of ghoSQLExecutor @SQL"SELECT Name, City, Zip FROM Customer" to aResults // Test for errors If (not(Err)) Begin // Process results here.. End
Example of SQLExecute without a result set.
Integer iAffectedRows Send SQLExecDirect of ghoSQLExecutor @SQL"UPDATE Customer SET NAME = 'Thomas Hardy', City = 'London' WHERE Customer_Number = 1" // Test for errors If (not(Err)) Begin Get piSQLAffectedRows of ghoSQLExecutor to iAffectedRows EndSee Also
Function SQLExecute | Procedure SQLExecute