The principle for procedures is the same; custom code needs to be annotated as well. Our example will be simple: to save the trees.
Procedures may change the content of the graph. Consequently, they are powerful tools. We could imagine a procedure that could perform the following:
- Consume an Internet source (RSS, JSON, and so on) to add content to the graph
- Clean up the graph from old data
It could be a procedure that creates valuable data or relations from the existing data.
From the generated graph of friends that we saw in Chapter 04, Getting Started with Cypher, on APOC, we will create nodes for each last name and link the Persons to their corresponding LastName node. Each LastName labeled node will have a lastName ...