Data.SqlExpr.TSQLConnection.ExecuteDirect
[–] Properties | |
---|---|
Type: function | |
Visibility: public | |
Source: Data.SqlExpr.pas Data.SqlExpr.hpp
| |
Unit: Data.SqlExpr | |
Parent: TSQLConnection |
Delphi
function ExecuteDirect(const SQL: string): Integer;
C++
int __fastcall ExecuteDirect(const System::UnicodeString SQL);
Description
Executes an SQL command that does not include parameters.
Call ExecuteDirect to execute a single parameterless command on the server without the overhead of using an SQL dataset or preparing the statement before it executes. If the statement ordinarily returns a cursor, ExecuteDirect executes the statement, but does not return a cursor.
SQL is the command to execute.
ExecuteDirect returns the number of rows that were affected by the execution of the SQL query.
Note: To execute an SQL statement that includes parameters or that returns a cursor, use the Execute method instead.