execute method
Future<int>
execute(
- String sql, {
- Object parameters = const <String, Object?>{},
- MssqlQueryOptions options = MssqlQueryOptions.defaults,
- Duration? timeout,
- MssqlCancellationToken? cancellationToken,
inherited
Runs sql for its effect and returns the affected row count.
Implementation
Future<int> execute(
String sql, {
Object parameters = const <String, Object?>{},
MssqlQueryOptions options = MssqlQueryOptions.defaults,
Duration? timeout,
MssqlCancellationToken? cancellationToken,
}) async {
final result = await query(
sql,
parameters: parameters,
options: options.withoutRetry,
timeout: timeout,
cancellationToken: cancellationToken,
);
return result.affectedRows;
}