Reputation: 475
g.V().has(label,"request_job").order().by("submit_time",incr).valueMap("submit_time")
==>[submit_time:[1330647978000]]
==>[submit_time:[1330652298000]]
When I use, order() query in Gremlin console, it is working fine. But when I try the same query in Java, I am not able to use "incr", it is showing that undefined symbol "incr"
.
How to use "incr" with order() in Java?
Kindly help me to resolve this problem.
Upvotes: 2
Views: 2711
Reputation: 6792
It is defined in the enum Order
(javadoc) which is automatically imported by the Gremlin Console. You should add the following import to your Java class:
import static org.apache.tinkerpop.gremlin.process.traversal.Order.*;
Upvotes: 4