从结果中排除 parent 个顶点

Exclude parent vertex from results

我有一个简单的图表,其中有一个 parent 和三个 children:

查询 children,我也得到了 parent:

select name
from (
  traverse in()
  from (
    select
    from group
    where name = 'Parent'
  )
)

结果:

name
Parent
Child 1
Child 2
Child 3

如何从查询结果中排除 parent?我宁愿不在我的应用程序代码中处理结果。

谢谢。

排除深度为零的地方似乎可以解决问题:

select name
from (
  traverse in()
  from (
    select
    from group
    where name = 'Parent'
  )
)
where $depth > 0

结果:

name
Child 1
Child 2
Child 3

要仅获取 children 名称,我建议这样查询:

select in('belongsTo').name as Name from Group where name = "Parent" unwind Name