The hierarchical query clause consists of two portions.
分级查询子句由两部分组成。
The hierarchical query clause is easier to understand than the RCTE syntax.
与RCTE语法相比,分级查询子句较更容易理解。
To get all subordinates over all levels, the PRIOR operator must be added to the CONNECT BY part of the hierarchical query clause.
要获取所有级别上的所有下属,必须将PRIOR运算符添加到分级查询子句的CONNECTBY部分。
A pseudo column is an identifier with a predefined name that holds information about the hierarchical query and that can be used like any column in a table.
伪列是具有预先定义的名称的标识符,其中包含关于分级查询的信息;它的用途类似于表中的任何列。
The following example shows a SELECT statement with a hierarchical query clause to return all direct subordinates for the manager Meier (employee number 101).
下列示例显示使用一个SELECT语句和一个分级查询子句来返回Meier经理(雇员编号为 101)的所有直接下属。
Adding an ORDER siblings BY clause which is only allowed in composition with the hierarchical query clause and will return the siblings in the predefined sequence.
添加一个ORDERSIBLINGSBY子句,该子句只能与分级查询子句组合使用,并且将按预先定义的顺序返回同级查询结果。
Adding an ORDER siblings BY clause which is only allowed in composition with the hierarchical query clause and will return the siblings in the predefined sequence.
添加一个ORDERSIBLINGSBY子句,该子句只能与分级查询子句组合使用,并且将按预先定义的顺序返回同级查询结果。
应用推荐