apoc.atomic.concat
Procedure APOC Core
apoc.atomic.concat(node/relatonship,propertyName,string) Concats the property’s value with the 'string' value
Signature
apoc.atomic.concat(container :: ANY?, propertyName :: STRING?, string :: STRING?, times = 5 :: INTEGER?) :: (container :: ANY?, property :: STRING?, oldValue :: ANY?, newValue :: ANY?)
Input parameters
Name | Type | Default |
---|---|---|
container |
ANY? |
null |
propertyName |
STRING? |
null |
string |
STRING? |
null |
times |
INTEGER? |
5 |
Usage Examples
The examples in this section are based on the following sample graph:
CREATE (:Person {name:'Tom',age: 40})
CREATE (:Person {name:'Will',age: 35})
CREATE (:Person {name:'David', children: ['Anne','Sam','Paul']})
CREATE (:Person {name:'John', cars: ['Class A','X3','Focus']})
CREATE (:Person {name:'Ryan', salary1:1800, salary2:1500});
The following concatenates
iam
to the name
property for Will
:MATCH (p:Person {name:'Will',age: 35})
CALL apoc.atomic.concat(p,"name",'iam',5)
YIELD oldValue, newValue
RETURN oldValue, newValue;
oldValue | newValue |
---|---|
"Will" |
"William" |