All Questions
32
questions
1
vote
1
answer
76
views
What Gremlin query can I write to create custom relationships between all pairs nodes that have a certain number of connections in common?
In AWS Neptune, I have a graph that has many clusters like the one defined below:
g.addV('person').property('name', 'John').as('p1')
.addV('person').property('name', 'Weihua').as('p2')
.addV('...
0
votes
1
answer
115
views
How do I pull specific property values from an injected object when adding a batch of edges in a Gremlin/TinkerPop traversal?
I want to add batches of edges to a JanusGraph db that already contains nodes. I want my edges to support setting dynamic/optional properties.
I've cobbled together the following traversal (based on ...
0
votes
1
answer
276
views
Cannot add vertices or edges to CosmosDB Gremlin graph with Python SDK
I have a Cosmos DB instance running the Gremlin API, and I am using the Python SDK on 3.7.
Currently I am trying to build a graph that models papers with topics and authors, by having each object ...
0
votes
1
answer
85
views
How to get the latest property of vertex from apache gremlin?
How to get the latest property of vertex from apache gremlin?
With the same key, We can add multiple properties.
vp[status->new]
vp[pre_signed_url->https://e-voting.s3.]
vp[pre_signed_url->...
1
vote
1
answer
506
views
How do you add edges to existing vertices in Gremlin-python?
What is the standard way to add edges between two already existing vertices in gremlin-python? I've tried numerous iterations including the two code versions below, but unfortunately they all lead to ...
0
votes
1
answer
1k
views
Use gremlin module for Python to add vertex to Amazon Neptune graph database
Synopsis
I am trying to use Python on an Amazon EC2 instance, in the same VPC as an Amazon Neptune instance, to add a vertex (node) to Neptune. Using the example code for Amazon Neptune, I constructed ...
0
votes
1
answer
432
views
Gremlin python - how to ignore property of type List when adding properties to vertex
I want to add persons as vertices in a graph which works with the following code:
from gremlin_python.process.graph_traversal import __
from gremlin_python.process.traversal import Column
persons = [{...
3
votes
1
answer
4k
views
How do I get all the edges, associated vertices, and the respective id, label and properties via gremlin-python?
I want to fetch all the edges and associated vertices from my AWS Neptune DB. In addition, I want the id, labels and properties for the nodes as well as edges.
My data is a stored as a property graph ...
1
vote
1
answer
929
views
Unable to list all vertices present in Janusgraph with ".toList()" using Gremlinpython
I have tried testing what is in a graph that I created to see whether nodes were indeed created.
The code to create a small graph for testing:
from gremlin_python import statics
from gremlin_python....
2
votes
0
answers
409
views
How to build gremlin query to add and drop vertex as part one transaction
I want to build a gremlin_python query dynamically that adds vertices and deletes vertices in single transaction.
For Ex: Lets say my graph has a vertex with property desc ='toBeDeleted'. I want to ...
9
votes
1
answer
4k
views
gremlin python - add multiple but an unknown number of properties to a vertex
I want to add more than one property to a vertex, but from the outset do not explicitly know what those properties might be. For example, say for one person to be added as vertex to the graph, we have ...
1
vote
1
answer
786
views
Using a combination between coalesce and values fails in gremlin-python
I am trying to project a property that may not exist in the node. According to the docs, this could be achieved by using coalesce with values.
Executing the query
g.V(1).project('unexisting').by(...
1
vote
1
answer
696
views
Adding multiple vertices, changing one property-value (tinkerpop3 + python GLV)
I'm trying to size down my code, but I need several instances of data of this type:
g.addV('A').property('a-type','thing-x').property('a-value',1).next()
g.addV('A').property('a-type','thing-x')....
2
votes
1
answer
2k
views
gremlin in python NameError not recognising functions
I am running Gremlin-Pyton in a Jupyter notebook and for some reason the following does not work:
g.V().group().by().by(bothE().count())
I keep getting the error:
NameError: name 'bothE' is not ...
1
vote
1
answer
3k
views
How do i upload tinkergraph into python/gremlin?
I am trying to use gremlin in python. I imported the following:
from gremlin_python.driver.driver_remote_connection import DriverRemoteConnection
from gremlin_python.structure.graph import Graph
...