Created
February 27, 2015 16:48
-
-
Save elliottcordo/c48f558236ad4881e72a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--create some non existent relationships | |
MATCH (m:CONTACT {name: "leslie"}), (k:CONTACT {name: "greg"}) MERGE (k)-[r:KNOWS]-(m) ; | |
MATCH (m:CONTACT {name: "elliott"}), (k:CONTACT {name: "greg"}) MERGE (k)-[r:FOLLOWS]->(m) ON CREATE SET r.since = ["2014-01-01"]; | |
--delete my connection to amex | |
MATCH (m:CONTACT {name: "elliott"})-[r]-(k {name: "American Express Company"}) delete r | |
--find 2nd level connections | |
match (elliott {name: "elliott"})-[r*0..2]-() | |
return * | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment