0
votes

When I run this command in OrientDB, I get all the nodes related, according to depth. (I get all depths, it is working)

TRAVERSE * FROM (select from Nodes where node = "817") while $depth<=5

I want only the vertexes ID, not all fields (*), from all levels (depth 5)

I also tried the commands bellow, but I can get only one depth, not all depths (depth 5 or more)

TRAVERSE V.out FROM (select from Nodes where node = "817") while $depth<=5 TRAVERSE outE() FROM (select from Nodes where node = "817") while $depth<=5 TRAVERSE out("related") FROM (select from Nodes where node = "817") while $depth<=5

Please help me. Thanks.

1

1 Answers

0
votes

Try this:

select @rid from (TRAVERSE * FROM (select from Nodes where node = "817") while $depth<=5)

Regards