[英]Arangodb: Traversal using only 1 type of edges
I have a edges collections with a "type" property. 我有一个带有“类型”属性的边集合。
What is an example of an AQL that traverse using only, for example,edge with type="A"? 仅使用类型为“ A”的边进行遍历的AQL的示例是什么?
As could be expected, you use filters, eg: 不出所料,您使用过滤器,例如:
FOR v, e, p IN 1..5 OUTBOUND 'collection/root' GRAPH 'graph'
FILTER p.edges[*].type == "A"
RETURN p
This query filters on the path p
, the 1..5
litmits the length of paths considered. 该查询对路径
p
过滤, 1..5
限制了所考虑路径的长度。
The documentation on traversals covers a lot of ground and gives examples to get you started: https://docs.arangodb.com/3.1/AQL/Graphs/Traversals.html 关于遍历的文档涵盖了很多基础知识,并提供了一些示例来帮助您入门: https : //docs.arangodb.com/3.1/AQL/Graphs/Traversals.html
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.