共用方式為


TSqlParser.ValidateIdentifier 方法

傳回名稱是否為有效的 SQL 識別項。

命名空間:  Microsoft.Data.Schema.ScriptDom.Sql
組件:  Microsoft.Data.Schema.ScriptDom.Sql (在 Microsoft.Data.Schema.ScriptDom.Sql.dll 中)

語法

'宣告
Public Function ValidateIdentifier ( _
    name As String _
) As Boolean
public bool ValidateIdentifier(
    string name
)
public:
bool ValidateIdentifier(
    String^ name
)
member ValidateIdentifier : 
        name:string -> bool 
public function ValidateIdentifier(
    name : String
) : boolean

參數

傳回值

型別:System.Boolean
true 如果提供的名稱是一個有效的 SQL 識別字 ; 否則為false。

.NET Framework 安全性

請參閱

參考

TSqlParser 類別

Microsoft.Data.Schema.ScriptDom.Sql 命名空間