简体   繁体   中英

ArangoDB: How to limit/skip results with Javascript graph functions?

I'm new to ArangoDB and I'm working on a Foxx service using the Javascript graph module. I see in AQL that the results of a graph traversal can be limited and offset, but I don't see the equivalent capability in the Javascript API (ie _neighbors function). Since there could be large numbers of neighbors involved, I hope there is a way to do this that doesn't require the full results of the neighbors function to be filtered by my script. Is there a lower level edge iteration approach that would allow me to build the result set directly?

Thanks!

Please don't use the javascript graph functions; they don't scale.

Please use the AQL graph support instead.

AQL can be invoked via db._query from foxx services easily.

You can then further examine the results and reduce them to your needs in .js inside the foxx service.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM