ExecuteImmediate Method (Database, SQLServer)
This feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.
The ExecuteImmediate method submits a Transact-SQL command batch on a connection, and directs execution or batch interpretation as specified by the application.
Set the ExecutionType argument using these values.
Batch execution continues on any error that does not break the connection.
No statement execution options set.
Ignore the command terminator in the script. Execute as a single batch.
Execute SET NOEXEC ON prior to batch execution. Execute SET NOEXEC OFF after batch execution.
Execute SET PARSEONLY ON prior to batch execution. Execute SET PARSEONLY OFF after batch execution.
Execute SET QUOTED_IDENTIFIER ON prior to batch execution. Execute SET QUOTED_IDENTIFIER OFF after batch execution.