gremlin-server

Gremlin: Count connections ignoring edges with a parallel edge in the opposing direction

放肆的年华 提交于 2021-01-05 09:47:21
问题 I'm currently working with a graph which indicates connections between vertices. The vertices can be connected in both directions. I am interested in knowing how many vertices are connected to each other regardless both the direction of the connection or if connections exist in both directions. So for example, in the graph sketched below the total number of connected vertices would be 3 (whilst a simple edge count would tell us there are 4 Due to the directionality of the edges this isn’t the

How to Perfrom Where Filter in Gremlin queries

天涯浪子 提交于 2020-07-23 06:52:36
问题 where(​ and​ (​ choose(constant(0).is(1),​ select('WorkLocation'). is(within('Not Updated')),​ select('WorkLocation')),​ ​ choose(constant(1).is(1),​ select('Status'). is(within('Red', 'Orange')),​ select('Status')),​ ​ choose(constant(0).is(1),​ select('ConfirmationDate'). is(between(637281491635663900, 637258237221895200)),​ select('ConfirmationDate'))​ )​ ) In the Above Where condition Query, I have to do a filter on three fields WorkLocation, Status, ConfirmationDate, I have used choose

How to Perfrom Where Filter in Gremlin queries

戏子无情 提交于 2020-07-23 06:51:17
问题 where(​ and​ (​ choose(constant(0).is(1),​ select('WorkLocation'). is(within('Not Updated')),​ select('WorkLocation')),​ ​ choose(constant(1).is(1),​ select('Status'). is(within('Red', 'Orange')),​ select('Status')),​ ​ choose(constant(0).is(1),​ select('ConfirmationDate'). is(between(637281491635663900, 637258237221895200)),​ select('ConfirmationDate'))​ )​ ) In the Above Where condition Query, I have to do a filter on three fields WorkLocation, Status, ConfirmationDate, I have used choose

can we relate a property with other property of same vertex

我的未来我决定 提交于 2020-06-29 03:21:29
问题 A sample vertex g.addV('a').property('vehicle','v1').property('time',1000).property(list,'vehicle','v2').property(list,'time',830) how can we map the values in property 'vehicle' to the values in property 'time'. I tired the following code g.V(1).hasKey('vehicle').map(hasKey('time')) To find path I tired following code g.V().hasLabel('a').repeat(out().simplePath()).until(hasLabel('h')).path().by(union(label(),values('vehicle','time')).fold()) can you help me please 回答1: Changing the data

can we relate a property with other property of same vertex

孤人 提交于 2020-06-29 03:21:23
问题 A sample vertex g.addV('a').property('vehicle','v1').property('time',1000).property(list,'vehicle','v2').property(list,'time',830) how can we map the values in property 'vehicle' to the values in property 'time'. I tired the following code g.V(1).hasKey('vehicle').map(hasKey('time')) To find path I tired following code g.V().hasLabel('a').repeat(out().simplePath()).until(hasLabel('h')).path().by(union(label(),values('vehicle','time')).fold()) can you help me please 回答1: Changing the data

403 Forbidden error for Gremlin to AWS Neptune

徘徊边缘 提交于 2020-05-28 06:53:29
问题 Thanks a lot for your help in advance I'm trying to setup my AWS Neptune environment by following the instruction at https://docs.aws.amazon.com/neptune/latest/userguide/get-started.html . The setup seems to be fine, and I could check the status by using the Neptune Notebook install. The status message as: { "status": "healthy", "startTime": "Tue May 12 04:24:52 UTC 2020", "dbEngineVersion": "1.0.2.2.R2", "role": "writer", "gremlin": { "version": "tinkerpop-3.4.3" }, "sparql": { "version":