Remove-SPODataConnectionSetting

 

**適用先:**SharePoint Server 2016

Removes a Business Connectivity Services connection.

構文

Remove-SPODataConnectionSetting -Name <String> -ServiceContext <SPServiceContextPipeBind> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]

Remove-SPODataConnectionSetting [-Identity] <ODataConnectionSettings> -ServiceContext <SPServiceContextPipeBind> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-WhatIf [<SwitchParameter>]]

Detailed Description

このコマンドレットには、複数のパラメーター セットが含まれています。使用できるのは、1 つのパラメーター セットのパラメーターだけであり、異なるパラメーター セットのパラメーターを組み合わせることはできません。パラメーター セットの使用法に関する詳しい情報については、「コマンドレット パラメーター セット」を参照してください。

Use the Remove-SPODataConnectionSetting cmdlet to remove a Business Connectivity Services connection for a particular Business Connectivity Services service application in the farm.

The metadata object associated with the Business Connectivity Services connection is also deleted.

注意

このコマンドレットは、社内環境のみに適用されます。SharePoint Online 管理シェルではこのコマンドを使用することはできません。

Windows PowerShell for SharePoint 製品のアクセス許可と最新情報については、「Windows PowerShell for SharePoint Server 2016 リファレンス」のオンライン ドキュメントをご覧ください。

パラメーター

Parameter Required Type Description

Identity

Required

Microsoft.SharePoint.BusinessData.SystemSpecific.OData.ODataConnectionSettings

Specifies the OData Connection Settings object.

ServiceContext

Required

Microsoft.SharePoint.PowerShell.SPServiceContextPipeBind

Specifies the service context which is in the form of an instance of an SPServiceContext object, an SPSiteAdministration object identifier, or a SPSite object. An example of a service context value is an identifier from the ID field, a string identifier, a URI, or a string representation of a GUID.

Name

Required

System.String

Specifies the name of the existing Business Connectivity Services connection.

AssignmentCollection

Optional

Microsoft.SharePoint.PowerShell.SPAssignmentCollection

適切な破棄を行うためにオブジェクトを管理します。 SPWebSPSite などのオブジェクトの使用によって大量のメモリが使用される場合があるので、Windows PowerShell スクリプトでこれらのオブジェクトを使用するには適切なメモリ管理が必要です。メモリの解放が必要になった場合は、 SPAssignment オブジェクトを使用して、変数へのオブジェクトの割り当てとオブジェクトの破棄を行うことができます。割り当てコレクションまたは Global パラメーターが使用されていない場合、 SPWebSPSite 、または SPSiteAdministration オブジェクトが使用されていると、オブジェクトは自動的に破棄されます。

注意

Global パラメーターが使用されている場合は、オブジェクトはすべてグローバル ストアに格納されます。 Stop-SPAssignment コマンドを使用してオブジェクトの使用または破棄を直接行わないと、メモリ不足のシナリオになる場合があります。

Confirm

Optional

System.Management.Automation.SwitchParameter

コマンドを実行する前に、確認のメッセージを表示します。詳細を表示するには、「 get-help about_commonparameters 」と入力します。

WhatIf

Optional

System.Management.Automation.SwitchParameter

コマンドを実行する代わりに、コマンドの実行結果を説明するメッセージを表示します。詳細を表示するには、「 get-help about_commonparameters 」と入力します。

Input Types

Return Types

----------------EXAMPLE 1------------

Remove-SPODataConnectionSetting -ServiceContext "http://contoso" -Name "ContosoServiceApp"

This example removes the Business Connectivity Services connection named ContosoServiceApp . Metadata properties are also removed.

----------------EXAMPLE 2------------

Remove-SPODataConnectionSetting -ServiceContext "http://contoso" -Name "ContosoServiceApp-metadata"

This example removes the Business Connectivity Services connection metadata named ContosoServiceApp .

The associated Business Connectivity Services connection object is also removed.

----------------EXAMPLE 3------------

$ConnectionVariable = Get-SPODataConnectionSettingMetadata -ServiceContext http://contoso -Name "ContosoServiceApp"

Remove-SPODataConnectionSetting -Identity $ConnectionVariable -ServiceContext "http://contoso"

This example removes the Business Connectivity Services and its associated metadata connection named ContosoServiceApp .

関連項目

Get-SPODataConnectionSetting
New-SPODataConnectionSetting
Set-SPODataConnectionSetting