gremlin> graph = TinkerFactory.createModern()
==>tinkergraph[vertices:6 edges:6]
gremlin> g = graph.traversal()
==>graphtraversalsource[tinkergraph[vertices:6 edges:6], standard]
gremlin> g.V(1).valueMap()
==>[name:[marko],age:[29]]
g.V(1).as('v').hasId(select('v').id())
hasId(Object id, Object... otherIds)
hasId(P<Object> predicate)
gremlin> g.V(1).as('v').has('name', select('v').by('age'))
==>v[1]
has(key, traversal): Remove the traverser if its object does not yield a result through the traversal off the property value.
(1) What happened?
(2) I don't understand the usefulness of the key in this signature. Or I'm wrong about how it works.
gremlin> g = TinkerFactory.createModern().traversal()
==>graphtraversalsource[tinkergraph[vertices:6 edges:6], standard]
gremlin> g.V(1).as('v').has('age', math('_*2').where(gt('v')).by().by('age'))==>v[1]
(3) Last question: how to use a has step filtering on the value returned by a select...by?
gremlin> g.V().as('a').both('knows').as('b').......1> where('a', gt('b')).......2> by('age').......3> select('a','b').......4> by(valueMap())==>[a:[name:[marko],age:[29]],b:[name:[vadas],age:[27]]]==>[a:[name:[josh],age:[32]],b:[name:[marko],age:[29]]]
--
You received this message because you are subscribed to the Google Groups "Gremlin-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gremlin-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gremlin-users/980e3b4e-d647-4db5-96d3-6975f2a8e1f4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Note that it is working in gremlin console:gremlin> g.addV('person').property('name','thomas')
==>v[15]
gremlin> g.V(15)
==>v[15]
but not with gremlin-server:gremlin> :> g.addV('person').property('name','thomas')
==>v[28]
gremlin> :> g.V(28)
gremlin>
--
You received this message because you are subscribed to the Google Groups "Gremlin-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gremlin-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gremlin-users/0ef600c2-19c6-4f9b-9dc3-181ec52ef7be%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Gremlin-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gremlin-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gremlin-users/d2aa086f-f055-434f-b294-c5fb5afbb32f%40googlegroups.com.