语言

NativeSqlConnectionException.SqlState 属性

定义

表示错误的 Microsoft SQL Server SQL 状态。

public:
 property System::String ^ SqlState { System::String ^ get(); };
public string SqlState { get; }
member this.SqlState : string
Public ReadOnly Property SqlState As String

属性值

一个五字符 String 的值,遵循ANSI SQL标准,表示错误代码

注解

SqlState 属性用于获取在处理SQL语句时,提供者返回的错误代码。

适用于