Questions tagged [opencypher]

For questions related to openCypher, a declarative graph query language

openCypher, a declarative graph database query language, is an open source project, including a language specification, located at here and the specification is available here.

105 questions
0
votes
1 answer

what does "parser_errposition()" function do in Apache-age?

I am trying to use the parse_cypher() function in the PGPOOL-II repository, We have imported Apache-age "parse_cypher()" function which is callable. And works fine for queries with correct cypher query syntax. But terminates the server when…
Kamlesh Kumar
  • 351
  • 1
  • 7
0
votes
1 answer

Schema validation mechanisms for LPG inside AWS Neptune

Hi can i know the schema validation mechanisms available for LPG inside AWS Neptune. For RDF we have a couple of them but i am not finding help on LPG. Thanks in Advance. I have tried mechanism for RDF such as SHACL but for LPG i am clueless on how…
Nikhil
  • 1
  • 1
0
votes
2 answers

Matching within nested list using in Apache AGE?

So I have a list of lists as a property. Like so: SELECT * FROM cypher('list_test', $$ CREATE(a: person {nickname: [['thomas', 'tomtom'], ['tom', 'tommy']]}) RETURN a $$) as (timothy agtype); I have tried the following queries: SELECT * FROM…
RU-D
  • 224
  • 8
0
votes
2 answers

"detailedMessage":"Operation failed due to conflicting concurrent operations (please retry), 0 transactions are currently rolling back

The Load operation on Neptune failed due to the deletion of files from s3 in between the s3 to Neptune load. Since then I am able to delete all the relationships that are present between nodes through opencypher query but unable to delete…
0
votes
2 answers

MemgraphDB: Using openCypher to add names to Karate club friendship network

I'm using Karate club friendship network sample data set to learn Cypher. Here is the description of it: The model consists of 34 users where some users are friends within a university karate club. User node - A user in the karate club. id - A…
Juliette Gia
  • 126
  • 6
0
votes
2 answers

Does MERGE clause in Cypher allows creating relationships without specifying the direction?

When I execute the query CREATE (p:Person)-[s:SPEAKS]-(l:Language) RETURN p, s, l;, I get the following error: Error: Query failed: Bidirectional relationship are not supported when creating an edge If I use MERGE instead of CREATE, the…
MasaZo
  • 43
  • 5
0
votes
5 answers

Why size() runs faster than length() when querying for the length of the path between two distant vertices?

I have a graph with multiple vertices and each of them represent an article from Wikipedia. The edges represent which article the first link of the current article text leads to. The article that is related to every other article is "Philosophy". I…
Matheus Farias
  • 716
  • 1
  • 10
0
votes
1 answer

How to make sure that created node will exist and will be unique in Memgraph?

If I get it correctly, this only enforces an existence constraint, not a uniqueness: CREATE CONSTRAINT ON (c:City) ASSERT exists (c.name); To make it unique, I would use a unique property constraint using the following syntax: CREATE CONSTRAINT ON…
KWriter
  • 1,024
  • 4
  • 22
0
votes
2 answers

Count the number of edges between one vertex to another

I have a graph that represents how Wikipedia articles are related to one another following the "Getting to Philosophy" phenomena, which is based on clicking on the very first link in the main text of an article, and repeating this processes for…
Matheus Farias
  • 716
  • 1
  • 10
0
votes
2 answers

How does the WHERE clause work in the apache AGE extension inside a cypher query?

This is the data setup: select * from cypher('test', $$ CREATE (david:Person {name: 'David'}) CREATE (alice:Person {name: 'Alice'}) CREATE (bob:Person {name: 'Bob'}) CREATE (charlie:Person {name: 'Charlie'}) CREATE (eve:Person {name: 'Eve'}) CREATE…
0
votes
1 answer

What is a correct way to update a property using Cypher?

I have nodes that have first name. I want to update all of the names John to Johan. Is there a difference between this two queries? The end result seems the same to me. Query 1 MATCH (p:Person) WHERE p.name= "John" SET p += {name: "Johan"}; Query…
Juliette Gia
  • 126
  • 6
0
votes
2 answers

How to query nodes that have no relationships in Memgraph?

I am trying to find a simple way to query the database to find orphan nodes - the ones that have no relationships. I tried running: MATCH (n:NodeA) WHERE NOT (n)-[]->(:NodeB) RETURN n; but it is not working in Memgraph. Does anyone know how to do…
KateLatte
  • 611
  • 1
  • 12
0
votes
7 answers

Apache AGE - Return nodes having a property with common pattern

Here I have two nodes with the property 'name' that contains the first name and last name of a person. I create the vertices as: SELECT * FROM cypher('graph', $$ CREATE (n:Person {name : "Michael Stone", age : 20}), (m: Person {name : "Michael…
Zainab Saad
  • 728
  • 1
  • 2
  • 8
0
votes
3 answers

Deleting a Specific property of a vertex

I have a vertex named CAR which has a few attributes as follows: CREATE (v:Car{ name: 'Alex', age: 27, manufactureDate: 2023 color: Yellow }) Now I want to delete the color property from the node. Can someone help me with this
0
votes
1 answer

Can I rename a property that already exist and that has values in it?

Is there a clause in Cypher that would allow me to rename property o.operating_system into o.os? I already have values assigned to a property.
ShymPi1999
  • 51
  • 3