SqlUserDefinedAggregateAttribute.IsInvariantToNulls SqlUserDefinedAggregateAttribute.IsInvariantToNulls SqlUserDefinedAggregateAttribute.IsInvariantToNulls SqlUserDefinedAggregateAttribute.IsInvariantToNulls Property


指示聚合是否与空值无关。Indicates whether the aggregate is invariant to nulls.

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


如果聚合与空值无关,则为 true;否则为 falsetrue if the aggregate is invariant to nulls; otherwise false.


由查询处理器,此属性是true如果聚合与空值无关。Used by the query processor, this property is true if the aggregate is invariant to nulls. S,{NULL} 的聚合,即是为 s。 聚合相同例如,聚合函数 MIN 和 MAX 如满足此属性,而 COUNT(*) 不。That is, the aggregate of S, {NULL} is the same as aggregate of S. For example, aggregate functions such as MIN and MAX satisfy this property, while COUNT(*) does not.

未正确设置此属性可能导致不正确的查询结果。Incorrectly setting this property can result in incorrect query results. 此属性不是一个优化程序提示;它会影响选择的计划和由查询返回的结果。This property is not an optimizer hint; it affects the plan selected and the results returned by the query.