SqlHierarchyId.GetAncestor 메서드

SQL Server 2012

Retrieves the SqlHierarchyId node n levels up the hierarchical tree.

네임스페이스:  Microsoft.SqlServer.Types
어셈블리:  Microsoft.SqlServer.Types(Microsoft.SqlServer.Types.dll)

[SqlMethodAttribute(DataAccess = DataAccessKind.None, SystemDataAccess = SystemDataAccessKind.None, 
	InvokeIfReceiverIsNull = false, OnNullCall = false, 
	IsDeterministic = true, IsPrecise = true, IsMutator = false)]
public SqlHierarchyId GetAncestor(
	int n
)

매개 변수

n
유형: System.Int32
An integer representing the number of levels to ascend in the hierarchy.

반환 값

유형: Microsoft.SqlServer.Types.SqlHierarchyId
SqlHierarchyId representing the nth ancestor of this.If a number greater than GetLevel is passed, null is returned.If a negative number is passed, an exception is raised indicating that the argument is out of range.

커뮤니티 추가 항목

추가
표시: