Commit 75ce99f
authored
Add SET n:Label and REMOVE n:Label (#2281)
NOTE: This PR was built with AI tools and verified by a human.
Implements Cypher SET and REMOVE operations for vertex labels in the unified
vertex table architecture. This allows dynamic label management on vertices.
SET n:Label
* Only works on vertices with no label.
* Auto-creates the label if it doesn't exist.
* Errors with hint if vertex already has a label:
"Multiple labels are not supported. Use REMOVE to clear the label first."
REMOVE n:Label
* Removes a vertex's specified label.
* Properties are preserved
* No-op if vertex already has no label
Added regression tests.
modified: regress/expected/cypher_remove.out
modified: regress/expected/unified_vertex_table.out
modified: regress/sql/unified_vertex_table.sql
modified: src/backend/executor/cypher_set.c
modified: src/backend/nodes/cypher_copyfuncs.c
modified: src/backend/nodes/cypher_outfuncs.c
modified: src/backend/nodes/cypher_readfuncs.c
modified: src/backend/parser/cypher_clause.c
modified: src/backend/parser/cypher_gram.y
modified: src/include/nodes/cypher_nodes.h1 parent 99dc094 commit 75ce99f
File tree
10 files changed
+1200
-174
lines changed- regress
- expected
- sql
- src
- backend
- executor
- nodes
- parser
- include/nodes
10 files changed
+1200
-174
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
463 | 463 | | |
464 | 464 | | |
465 | 465 | | |
466 | | - | |
| 466 | + | |
467 | 467 | | |
468 | 468 | | |
469 | 469 | | |
| |||
0 commit comments