You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@age.apache.org by GitBox <gi...@apache.org> on 2021/08/31 13:26:21 UTC
[GitHub] [incubator-age] joefagan commented on issue #110: How to remove a vertex
joefagan commented on issue #110:
URL: https://github.com/apache/incubator-age/issues/110#issuecomment-909236348
That error message was from an earlier release eg 0.4.0
Please check that the following shows a later version.
`select extname, extversion from pg_extension where extname='age';`
extname | extversion
---------+------------
age | 0.5.0
(1 row)
The following was run with version 0.5.0 that shows creating and deleting nodes
```
CREATE EXTENSION age;
LOAD 'age';
SET search_path = ag_catalog, "$user", public;
SELECT create_graph('my_graph_name');
SELECT * from cypher('my_graph_name', $$
CREATE (a:Part {part_num: '123'}),
(b:Part {part_num: '345'}),
(c:Part {part_num: '456'}),
(d:Part {part_num: '789'})
$$) as (a agtype);
-- Delete a node
SELECT * from cypher('my_graph_name', $$
MATCH (a:Part {part_num: '123'}) DELETE a
$$) as (a agtype);
-- Confirm node deletion
SELECT * from cypher('my_graph_name', $$
MATCH (a)
RETURN a
$$) as (a agtype);
```
a
-------------------------------------------------------------------------------------
{"id": 844424930131970, "label": "Part", "properties": {"part_num": "345"}}::vertex
{"id": 844424930131971, "label": "Part", "properties": {"part_num": "456"}}::vertex
{"id": 844424930131972, "label": "Part", "properties": {"part_num": "789"}}::vertex
(3 rows)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@age.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org