This example demonstrates how to ingest a Cypherl file in Memgraph using a Java driver and query a multi-hop traversal query.
The script performs the following actions:
- Cleans the database in the analytical mode
- Imports the Cypherl file
- Queries the
To run Memgraph Enterprise using Docker:
docker run -it --rm -p 7687:7687 memgraph/memgraph-mage:3.2Java version: 23 (you can change it in the pom.xml file)
- Run
mvn compile - Run
mvn exec:java -Dexec.mainClass="com.example.memgraph.App" -Dexec.args="/path/to/best-practices/datasets/energy-management-memgraph-lab/energy-management-system.cypherl"
This example was built and tested with:
- Memgraph v3.2.0
If you run into any issues or have questions, feel free to reach out on the Memgraph Discord server. We're happy to help!
🛑 This example runs on Memgraph Community Edition.