ExpectedSqlExceptionAttribute.MatchFirstError Property

Gets a value that indicates whether the expected severity, state, and error number are to be matched against the first SqlError in the SqlException.

Namespace:  Microsoft.Data.Schema.UnitTesting
Assembly:  Microsoft.Data.Schema.UnitTesting (in Microsoft.Data.Schema.UnitTesting.dll)

Syntax

'Declaration
Public Property MatchFirstError As Boolean
public bool MatchFirstError { get; set; }
public:
property bool MatchFirstError {
    bool get ();
    void set (bool value);
}
member MatchFirstError : bool with get, set
function get MatchFirstError () : boolean
function set MatchFirstError (value : boolean)

Property Value

Type: System.Boolean
true to match the expected severity, state, and error number to the first SqlError in the exception; false to match the expected severity, state, and error number to any SqlError in the exception.

.NET Framework Security

See Also

Reference

ExpectedSqlExceptionAttribute Class

Microsoft.Data.Schema.UnitTesting Namespace

SqlException

SqlError