SqlUserDefinedAggregateAttribute.IsInvariantToDuplicates 屬性

定義

指出彙總是否不因重複項目而異。Indicates whether the aggregate is invariant to duplicates.

public:
 property bool IsInvariantToDuplicates { bool get(); void set(bool value); };
public bool IsInvariantToDuplicates { get; set; }
member this.IsInvariantToDuplicates : bool with get, set
Public Property IsInvariantToDuplicates As Boolean

屬性值

Boolean

如果彙總是不因重複項目而異,則為 true,否則為 falsetrue if the aggregate is invariant to duplicates; otherwise false.

備註

由查詢處理器使用, true 如果匯總不是重複的,這個屬性就是。Used by the query processor, this property is true if the aggregate is invariant to duplicates. 也就是說,S,{X} 的匯總與 S 中的匯總相同。例如,「最小值」和「最大值」之類的彙總函式會滿足此屬性,而 SUM 則不會。That is, the aggregate of S, {X} is the same as aggregate of S when X is already in S. For example, aggregate functions such as MIN and MAX satisfy this property, while SUM does not.

不正確地設定此屬性可能會產生不正確的查詢結果。Incorrectly setting this property can result in incorrect query results. 這個屬性不是優化工具提示;它會影響所選取的計畫和查詢所傳回的結果。This property is not an optimizer hint; it affects both the plan selected and the results returned by the query.

適用於