Table of Contents

Enum ExecutionResultCode

Namespace
ItTiger.TigerQuery.Engine
Assembly
ItTiger.TigerQuery.dll
Identifies the outcome recorded in an ExecutionResult.
public enum ExecutionResultCode

Fields

BatchFailed = 1
At least one batch attempt failed without a stronger failure occurring.

The failure is either a caught nonfatal SqlException or a SqlBatchErrorException built from server errors the provider reported as informational messages.

The code is produced whether the effective :ON ERROR policy stopped the run at the failing batch or continued past it. Under a continue policy, later batches still run and ExecutedBatches counts their successes, but they never restore Success.

ConnectionFailed = 4
Represents a failure while establishing the SQL connection.
Fatal = 2
A fatal SQL Server error stopped execution.
FatalException = 7
A TigerQueryException stopped batch execution.
OutputFailed = 8
Routing, serialization, or writing of script output failed.

Exception is the OutputRoutingException that caused the failure. An output failure stops the run immediately whatever the effective :ON ERROR policy is, because continuing would execute later SQL while losing or corrupting its requested output.

SQL Server may already have completed the command, and may have committed side effects, before the failure was discovered. The batch is nevertheless counted as failed.

ParseError = 5
Represents a TigerQuery/sqlcmd structural parsing failure.
Success = 0
Every started batch attempt succeeded.This code requires FailedBatches to be zero. A failed attempt that an effective continue-on-error policy ignored still ends the run as BatchFailed, because the result code is the outcome of the run rather than a record of whether it stopped early.
UnhandledException = 6
An unexpected non-SQL exception stopped batch execution.
UserCancelled = 3
Cancellation was observed while a batch execution was in progress.

Remarks

Parser, connection-opening, and some cancellation exceptions currently escape the run method rather than being normalized into a result; the corresponding values remain part of the public result-code contract for consumers.