Share via


Move-SPProfileManagedMetadataProperty

 

適用版本: SharePoint Server 2010

上次修改主題的時間: 2015-03-09

將多字串值移入字詞組。

Syntax

Move-SPProfileManagedMetadataProperty -Identity <String> -ProfileServiceApplicationProxy <SPServiceApplicationProxyPipeBind> [-AssignmentCollection <SPAssignmentCollection>] [-AvailableForTagging <SwitchParameter>] [-Confirm [<SwitchParameter>]] [-TermSetName <String>] [-WhatIf [<SwitchParameter>]]

詳細描述

使用 Move-SPProfileManagedMetadataProperty 指令程式將多字串或單一字串屬性值移入您指定的字詞組。如果您未指定字詞組,則值會移入關鍵字詞組。在執行指令程式之後新增到屬性的任何新值將移入您指定的字詞組。

從 Microsoft Office SharePoint Server 2007 升級使用者設定檔應用程式之後,就無法使用單一字串及多字串值屬性,除非執行 Move-SPProfileManagedMetadataProperty 指令程式,將它們對應到 Managed Metadata Service 內的字詞組。

如需 Windows PowerShell for SharePoint Server 2010 的權限及最新資訊,請參閱 TechNet (https://go.microsoft.com/fwlink/?LinkId=163183)。

Parameters

參數 必要 類型 描述

Identity

必要

System.String

指定需要移轉到分類的設定檔屬性名稱。

ProfileServiceApplicationProxy

必要

Microsoft.SharePoint.PowerShell.SPServiceApplicationProxyPipeBind

指定要使用的使用者設定檔服務應用程式 Proxy 的名稱。

AssignmentCollection

選用

Microsoft.SharePoint.PowerShell.SPAssignmentCollection

為能適當處置物件而管理物件。使用 SPWebSPSite 等物件可能會耗用大量的記憶體,因此在 Windows PowerShell 指令碼中使用這些物件時,必須適當地管理記憶體。您可以使用 SPAssignment 物件將物件指派給變數,並在不需要時處置這些物件,以釋放記憶體。使用 SPWebSPSiteSPSiteAdministration 物件時,若未使用指派集合或 Global 參數,將會自動處置這些物件。

注意

使用 Global 參數時,所有物件會包含在全域儲存區內。若未立即使用物件,或未使用 Stop-SPAssignment 命令處置物件,將會發生記憶體不足的狀況。

AvailableForTagging

選用

System.Management.Automation.SwitchParameter

判斷結果字詞組中的字詞是否可以用於受管理的中繼資料標籤。如果字詞組有 30,000 個以上的字詞,則對受管理的中繼資料標籤使用它,可能導致用戶端電腦上發生效能問題。因為大部分設定檔屬性可能具有 30,000 個以上的字詞,所以預設值為 No

Confirm

選用

System.Management.Automation.SwitchParameter

執行命令之前,會先提示您進行確認。如需詳細資訊,請輸入下列命令:get-help about_commonparameters

TermSetName

選用

System.String

指定時,即會建立字詞組名稱。如果未指定 TermSetName 參數,則屬性會對應到受管理的中繼資料服務中的 Keywords 字詞組。

WhatIf

選用

System.Management.Automation.SwitchParameter

顯示訊息描述命令效果,而非描述命令執行的效果。如需詳細資訊,請輸入下列命令:get-help about_commonparameters

輸入類型

傳回類型

Example

---------------範例 1------------------

Move-SPProfileManagedMetadataProperty -Identity SPS-Interests -TermSetName Interests -AvailableForTagging -ProfileServiceApplicationProxy dbc4ccf5-b245-4e0f-8696-235402f83260

此範例會將 SPS-Interests 屬性中的值移入稱為 Interests 的字詞組,並將該字詞組標示為可用於標籤。

---------------範例 2------------------

Get-SPServiceApplicationProxy | ?{$_.DisplayName.Contains("User Profile Service")} | Move-SPProfileManagedMetadataProperty -Identity SPS-Interests -TermSetName Interests -AvailableForTagging

此範例會執行與範例 1 相同的工作,但是會使用 Get-SPServiceApplicationProxy 指令程式,以管道輸出 ProfileServiceApplicationProxy 參數的結果。