Share via


Ole Automation Procedures 選項

使用 Ole Automation Procedures 選項可指定 OLE Automation 物件是否可在 Transact-SQL 批次內部啟動。您也可以使用「介面區組態」工具來設定此選項。如需詳細資訊,請參閱<介面區組態>。

Ole Automation Procedures 選項可設定為下列值:

  • 0
    停用 OLE Automation Procedures。這是 SQL Server 2005 新執行個體的預設值。
  • 1
    啟用 OLE Automation Procedures。

啟用 OLE Automation Procedures 時,對 sp_OACreate 的呼叫會啟動 OLE 共用執行環境。

您可以使用 sp_configure 系統預存程序來檢視和變更 Ole Automation Procedures 選項目前的值。

範例

下列範例顯示如何檢視 OLE Automation Procedures 的目前設定。

EXEC sp_configure 'Ole Automation Procedures';
GO

下列範例顯示如何啟用 OLE Automation Procedures。

sp_configure 'show advanced options', 1;
GO
RECONFIGURE;
GO
sp_configure 'Ole Automation Procedures', 1;
GO
RECONFIGURE;
GO

請參閱

概念

設定伺服器組態選項

其他資源

sp_configure (Transact-SQL)
RECONFIGURE (Transact-SQL)
介面區組態

說明及資訊

取得 SQL Server 2005 協助