|
|
|
|
|
- Running the query
- Retrieving the query result
- INSERT query
- Managing text memos
- Managing binary memos
- SQL query (SQLExec or queries created in the query editor)
- Comparison with the syntax of HExecuteSQLQuery
- SQLExec and threads
- Limitations in PHP
SQLExec (Function) In french: SQLExec Names and runs an SQL query. Caution: SQLExec does not start the process for retrieving the result in memory. The result is retrieved during the first call to one of the following functions: SQLFirst, SQLTable or SQLFetch. Remark: To handle a binary memo in a query, use the WDBinaryMemo keyword in the text of your query (for more details, see remarks). Syntax
Running an SQL query Hide the details
<Result> = SQLExec(<SQL query text> , <Query name>)
<Result>: Boolean - True if the query was executed,
- False otherwise. If the query was not run, the error message can be returned by the SQL.MesError variable once SQLInfo has been run.
<SQL query text>: Character string SQL code of query to run. <Query name>: Character string Name associated with the query text. Corresponds to:- the logical query name.
- the name and full path of query (".WDR" file).
Remarks Running the query The information regarding the query execution is returned by SQLInfo. The SQL.NbCol variable contains the number of columns found in the query result. Once it was run and processed, the query must be freed by SQLClose. Retrieving the query result Then, the query result can be: - Transferred into a table or into a list box (SQLTable).
- Transferred into controls or variables (SQLAssociate).
- Retrieved line by line (SQLFetch).
SQLExec and threads When SQLExec is run in a secondary thread, the connection must be established in the same thread: the connection cannot be established in the main thread (project or window). The connection established by SQLConnect is not shared in the other threads.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|