New-SPEnterpriseSearchMetadataManagedProperty
向共享的搜索应用程序中添加托管属性。
语法
Default (默认值)
New-SPEnterpriseSearchMetadataManagedProperty
[-AssignmentCollection <SPAssignmentCollection>]
[-Confirm]
[-DefaultForQueryIndependentRank <UInt32>]
[-Description <String>]
[-EnabledForQueryIndependentRank <Boolean>]
[-EnabledForScoping <Boolean>]
[-FullTextQueriable <Boolean>]
[-IncludeInAlertSignature <Boolean>]
[-IncludeInMd5 <Boolean>]
-Name <String>
[-NameNormalized <Boolean>]
[-NoWordBreaker <Boolean>]
[-Queryable <Boolean>]
[-RemoveDuplicates <Boolean>]
[-RespectPriority <Boolean>]
[-Retrievable <Boolean>]
[-SafeForAnonymous <Boolean>]
-SearchApplication <SearchServiceApplicationPipeBind>
[-SiteCollection <Guid>]
[-Tenant <Guid>]
-Type <Int32>
[-UserFlags <Int16>]
[-WhatIf]
[<CommonParameters>]
说明
此 cmdlet 将创建新的托管属性。 SPEnterpriseSearchMetadataManagedProperty 表示企业级搜索元数据属性架构中的一个托管属性。
有关适用于 SharePoint 产品的 Windows PowerShell 的权限和最新信息,请参阅 SharePoint Server cmdlet。
示例
例
$ssa = Get-SPEnterpriseSearchServiceApplication
New-SPEnterpriseSearchMetadataManagedProperty -Name AboutMeUpdate -SearchApplication $ssa -Type 4
本示例在默认搜索服务应用程序中创建名为 AboutMeUpdate 的新托管属性,并将其类型设置为 DateTime。
参数
-AssignmentCollection
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
管理对象以便正确进行处理。 使用 SPWeb 或 SPSite 等对象可能会耗用大量内存,而且在 Windows PowerShell 脚本中使用这些对象需要正确管理内存。 通过使用 SPAssignment 对象,可以将对象分配给变量,然后在不需要这些对象时对它们进行处理,以释放内存。 在使用 SPWeb、SPSite 或 SPSiteAdministration 对象时,如果不使用分配集合或 Global 参数,则会自动处理这些对象。
使用全局参数时,所有对象均包含在全局存储中。
如果未立即使用对象,或未通过使用 Stop-SPAssignment 命令来处理对象,则可能会发生内存不足的情况。
参数属性
| 类型: | SPAssignmentCollection |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | True |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-Confirm
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
执行命令前,看到确认提示。
有关详细信息,请键入以下命令:get-help about_commonparameters
参数属性
| 类型: | SwitchParameter |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | cf |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-DefaultForQueryIndependentRank
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定在独立于查询的排名(相关性)中使用时托管属性是必需的。
参数属性
| 类型: | UInt32 |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | def |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-Description
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
向元数据托管属性添加说明。
键入的值必须为有效的字符串。
参数属性
| 类型: | String |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | d |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-EnabledForQueryIndependentRank
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定在独立于查询的分级工作的自定义分级模型中使用时,该托管属性是强制的。
键入的值必须属于自定义模型 XML 中独立于查询的下列分级功能之一:
- queryIndependentFeature
- categoryFeature
- languageFeature
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | qir |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-EnabledForScoping
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定可在范围定义中使用托管属性。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | e |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-FullTextQueriable
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定可在企业级搜索 SQL 查询中使用托管属性。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | f |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-IncludeInAlertSignature
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定是否应在警报签名中包含此托管属性。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | ia |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-IncludeInMd5
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定在爬网程序使用的哈希中包含托管属性以确定文档是否已更改。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | im5 |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-Name
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定新托管属性的名称。
类型必须是托管属性的有效名称,例如 ManagedProperty1。
参数属性
| 类型: | String |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
(All)
| Position: | Named |
| 必需: | True |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-NameNormalized
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定是否应规范化托管属性的值,即启用以返回查询中使用的不区分字母大小写和音调符号的结果。 如果值设置为 True,则对值进行规范化处理。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | nn |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-NoWordBreaker
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定分词系统将处理此托管属性的值。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | 西北 |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-Queryable
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定此托管属性是否可查询。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | q |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-RemoveDuplicates
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定将删除重复的托管属性值。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | rd |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-RespectPriority
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定当映射的已爬网属性包含多个值并且 RespectPriority 设置为 true 时,仅复制第一个映射的已爬网属性。 否则将复制具有值的所有已映射的已爬网属性。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | rp |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-Retrievable
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定此托管属性是否可检索。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | r |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-SafeForAnonymous
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定是否允许匿名搜索的搜索结果中显示该属性的内容。
参数属性
| 类型: | Boolean |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | sfa |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-SearchApplication
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定包含托管属性集合的搜索应用程序。
该类型必须是有效的搜索应用程序名称 (例如 SearchApp1) 或有效的 SearchServiceApplication 对象的实例。
参数属性
| 类型: | SearchServiceApplicationPipeBind |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
(All)
| Position: | Named |
| 必需: | True |
| 来自管道的值: | True |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-SiteCollection
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定返回的托管属性位于网站集 (SPSite) 范围内。
键入的值必须为用于指定属性集的 12345678-90ab-cdef-1234-567890bcdefgh 形式的有效 GUID。
参数属性
| 类型: | Guid |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-Tenant
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定返回的托管属性位于租户范围内。
键入的值必须为用于指定属性集的 12345678-90ab-cdef-1234-567890bcdefgh 形式的有效 GUID。
参数属性
| 类型: | Guid |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-Type
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
指定新托管属性的数据类型。
类型必须是以下数据类型之一:
1 = 文本
2 = 整数
3 = Decimal
4 = DateTime
5 = 是否
6 = Binary
7 = Double
参数属性
| 类型: | Int32 |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | t |
参数集
(All)
| Position: | Named |
| 必需: | True |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-UserFlags
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
保留供以后使用。
参数属性
| 类型: | Int16 |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | u |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
-WhatIf
适用:SharePoint Server 2010、SharePoint Server 2013、SharePoint Server 2016 SharePoint Server 2019
显示一条描述命令作用的消息,而不执行命令。
有关详细信息,请键入以下命令:get-help about_commonparameters
参数属性
| 类型: | SwitchParameter |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | 无线 |
参数集
(All)
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | False |
| 来自剩余参数的值: | False |
CommonParameters
此 cmdlet 支持通用参数:-Debug、-ErrorAction、-ErrorVariable、-InformationAction、-InformationVariable、-OutBuffer、-OutVariable、-PipelineVariable、-ProgressAction、-Verbose、-WarningAction 和 -WarningVariable。 有关详细信息,请参阅 about_CommonParameters。