DbException.SqlState Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
For database providers which support it, contains a standard SQL 5-character return code indicating the success or failure of the database operation. The first 2 characters represent the class of the return code (e.g. error, success), while the last 3 characters represent the subclass, allowing detection of error scenarios in a database-portable way.
For database providers which don't support it, or for inapplicable error scenarios, contains null
.
public:
virtual property System::String ^ SqlState { System::String ^ get(); };
public virtual string? SqlState { get; }
member this.SqlState : string
Public Overridable ReadOnly Property SqlState As String
Property Value
A standard SQL 5-character return code, or null
.