Class BatchScriptExecutor
An implementation of the IScriptExecutor interface that executes SQL scripts using batch processing when supported by the database provider.
public class BatchScriptExecutor : IScriptExecutor
- Inheritance
-
BatchScriptExecutor
- Implements
- Derived
- Inherited Members
Remarks
This class processes scripts by splitting them into individual SQL statements and executing them as a batch if the provider permits it. If batch execution is not supported, individual commands are executed sequentially.
Constructors
BatchScriptExecutor(string)
An implementation of the IScriptExecutor interface that executes SQL scripts using batch processing when supported by the database provider.
public BatchScriptExecutor(string providerName)
Parameters
providerNamestringThe name of the database provider used to establish the connection.
Remarks
This class processes scripts by splitting them into individual SQL statements and executing them as a batch if the provider permits it. If batch execution is not supported, individual commands are executed sequentially.
Methods
Execute(string, string)
Executes a SQL script against the specified database connection.
public virtual void Execute(string connectionString, string script)