apoc.refactor

Qualified Name Type

apoc.refactor.categorize(sourceKey String, type String, outgoing Boolean, label String, targetKey String, copiedKeys [String], batchSize Integer) - creates new category nodes from nodes in the graph with the specified sourceKey as one of its property keys. The new category nodes are then connected to the original nodes with a relationship of the given type.

Procedure

apoc.refactor.cloneNodes(nodes [Node], withRelationships Boolean, skipProperties [String]) - clones the given nodes with their labels and properties. It is possible to skip any node properties using skipProperties (note: this only skips properties on nodes and not their relationships).

Procedure

apoc.refactor.cloneSubgraph(nodes [Node], rels [Rel], config Map<String, Any>) - clones the given nodes with their labels and properties (optionally skipping any properties in the skipProperties list via the config map), and clones the given relationships. If no relationships are provided, all existing relationships between the given nodes will be cloned.

Procedure

apoc.refactor.cloneSubgraphFromPaths(paths [Path], config Map<String, Any>) - clones a sub-graph defined by the given list of paths. It is possible to skip any node properties using the skipProperties list via the config map.

Procedure

apoc.refactor.collapseNode(nodes Any, relType String) - collapses the given node and replaces it with a relationship of the given type.

Procedure

apoc.refactor.deleteAndReconnect(path Path, nodes [Node], config Map<String, Any>) - removes the given nodes from the path and reconnects the remaining nodes.

Procedure

apoc.refactor.extractNode(rels Any, labels [String], outType String, inType String) - expands the given relationships into intermediate nodes. The intermediate nodes are connected by the given 'OUT' and 'IN' types.

Procedure

apoc.refactor.from(rel Rel, newNode Node) - redirects the given relationship to the given start node.

Procedure

apoc.refactor.invert(rel Rel) - inverts the direction of the given relationship.

Procedure

apoc.refactor.mergeNodes(nodes [Node], config Map<String, Any>) - merges the given list of nodes onto the first node in the list. All relationships are merged onto that node as well.

Procedure

apoc.refactor.mergeRelationships(rels [Rel], config Map<String, Any>) - merges the given list of relationships onto the first relationship in the list.

Procedure

apoc.refactor.normalizeAsBoolean(entity Any, propertyKey String, trueValues [Any], falseValues [Any]) - refactors the given property to a boolean.

Procedure

apoc.refactor.rename.label(oldLabel String, newLabel String, nodes [Node]) - renames the given label from 'oldLabel' to 'newLabel' for all nodes. If a list of nodes is provided, the renaming is applied to the nodes within this list only.

Procedure

apoc.refactor.rename.nodeProperty(oldName String, newName String, nodes [Node], config Map<String, Any>) - renames the given property from 'oldName' to 'newName' for all nodes. If a list of nodes is provided, the renaming is applied to the nodes within this list only.

Procedure

apoc.refactor.rename.type(oldType String, newType String, rels [Rel], config Map<String, Any>) - renames all relationships with type 'oldType' to 'newType'. If a list of relationships is provided, the renaming is applied to the relationships within this list only.

Procedure

apoc.refactor.rename.typeProperty(oldName String, newName String, rels [Rel], config Map<String, Any>) - renames the given property from 'oldName' to 'newName' for all relationships. If a list of relationships is provided, the renaming is applied to the relationships within this list only.

Procedure

apoc.refactor.setType(rel Rel, newType String) - changes the type of the given relationship.

Procedure

apoc.refactor.to(rel Rel, endNode Node) - redirects the given relationship to the given end node.

Procedure