RNeo4j (version 1.6.4)

updateProp: Update Node and Relationship Properties

Description

For a node or relationship object, update its properties. Existing properties can be overridden and new properties can be added.

Usage

updateProp(entity, ...)

Arguments

entity
A node or relationship object.
...
A named list. Property updates in the form key = value.

Value

A node or relationship object.

See Also

deleteProp

Examples

Run this code
## Not run: 
# graph = startGraph("http://localhost:7474/db/data/")
# clear(graph)
# 
# alice = createNode(graph, "Person", name = "Alice")
# bob = createNode(graph, "Person", name = "Bob")
# 
# alice = updateProp(alice, age = 24, eyes = "green")
# 
# newProps = list(age = 25, eyes = "brown")
# bob = updateProp(bob, newProps)
# 
# alice
# bob
# ## End(Not run)

Run the code above in your browser using DataLab