From 427c6e3aaf345b6bc56d18f4543a8913fcc09c7f Mon Sep 17 00:00:00 2001 From: jievince <38901892+jievince@users.noreply.github.com> Date: Wed, 16 Feb 2022 18:31:12 +0800 Subject: [PATCH] add dataset basketballplayer --- data/basketballplayer.ngql | 709 +++++++++++++++++-------------------- data/nba.ngql | 384 ++++++++++++++++++++ 2 files changed, 709 insertions(+), 384 deletions(-) create mode 100644 data/nba.ngql diff --git a/data/basketballplayer.ngql b/data/basketballplayer.ngql index 7612674..e7132ac 100644 --- a/data/basketballplayer.ngql +++ b/data/basketballplayer.ngql @@ -1,384 +1,325 @@ -CREATE SPACE nba(VID_TYPE=FIXED_STRING(32));USE nba; - -CREATE TAG IF NOT EXISTS player(name string, age int);\ - -CREATE TAG IF NOT EXISTS team(name string);\ - -CREATE TAG IF NOT EXISTS bachelor(name string, speciality string);\ - -CREATE EDGE IF NOT EXISTS like(likeness int);\ - -CREATE EDGE IF NOT EXISTS serve(start_year int, end_year int);\ - -CREATE EDGE IF NOT EXISTS teammate(start_year int, end_year int);\ - -CREATE TAG INDEX IF NOT EXISTS player_name_index ON player(name(64));\ - -CREATE TAG INDEX IF NOT EXISTS player_age_index ON player(age);\ - -CREATE TAG INDEX IF NOT EXISTS team_name_index ON team(name(64));\ - -CREATE EDGE INDEX IF NOT EXISTS like_index ON like(likeness);\ - -CREATE EDGE INDEX IF NOT EXISTS serve_index1 ON serve(start_year);\ - -CREATE EDGE INDEX IF NOT EXISTS serve_index2 ON serve(end_year);\ - -CREATE EDGE INDEX IF NOT EXISTS teammate_index1 ON teammate(start_year);\ - -CREATE EDGE INDEX IF NOT EXISTS teammate_index2 ON teammate(end_year);\ - -:sleep 10 - -INSERT VERTEX player(name, age) VALUES\ - "Null1": (null, -1),\ - "Null2": (null, -2),\ - "Null3": (null, -3),\ - "Null4": (null, -4),\ - "Nobody": ("Nobody", 0),\ - "Amar'e Stoudemire": ("Amar'e Stoudemire", 36),\ - "Russell Westbrook": ("Russell Westbrook", 30),\ - "James Harden": ("James Harden", 29),\ - "Kobe Bryant": ("Kobe Bryant", 40),\ - "Tracy McGrady": ("Tracy McGrady", 39),\ - "Chris Paul": ("Chris Paul", 33),\ - "Boris Diaw": ("Boris Diaw", 36),\ - "LeBron James": ("LeBron James", 34),\ - "Klay Thompson": ("Klay Thompson", 29),\ - "Kristaps Porzingis": ("Kristaps Porzingis", 23),\ - "Jonathon Simmons": ("Jonathon Simmons", 29),\ - "Marco Belinelli": ("Marco Belinelli", 32),\ - "Luka Doncic": ("Luka Doncic", 20),\ - "David West": ("David West", 38),\ - "Tony Parker": ("Tony Parker", 36),\ - "Danny Green": ("Danny Green", 31),\ - "Rudy Gay": ("Rudy Gay", 32),\ - "LaMarcus Aldridge": ("LaMarcus Aldridge", 33),\ - "Tim Duncan": ("Tim Duncan", 42),\ - "Kevin Durant": ("Kevin Durant", 30),\ - "Stephen Curry": ("Stephen Curry", 31),\ - "Ray Allen": ("Ray Allen", 43),\ - "Tiago Splitter": ("Tiago Splitter", 34),\ - "DeAndre Jordan": ("DeAndre Jordan", 30),\ - "Paul Gasol": ("Paul Gasol", 38),\ - "Aron Baynes": ("Aron Baynes", 32),\ - "Cory Joseph": ("Cory Joseph", 27),\ - "Vince Carter": ("Vince Carter", 42),\ - "Marc Gasol": ("Marc Gasol", 34),\ - "Ricky Rubio": ("Ricky Rubio", 28),\ - "Ben Simmons": ("Ben Simmons", 22),\ - "Giannis Antetokounmpo": ("Giannis Antetokounmpo", 24),\ - "Rajon Rondo": ("Rajon Rondo", 33),\ - "Manu Ginobili": ("Manu Ginobili", 41),\ - "Kyrie Irving": ("Kyrie Irving", 26),\ - "Carmelo Anthony": ("Carmelo Anthony", 34),\ - "Dwyane Wade": ("Dwyane Wade", 37),\ - "Joel Embiid": ("Joel Embiid", 25),\ - "Damian Lillard": ("Damian Lillard", 28),\ - "Yao Ming": ("Yao Ming", 38),\ - "Kyle Anderson": ("Kyle Anderson", 25),\ - "Dejounte Murray": ("Dejounte Murray", 29),\ - "Blake Griffin": ("Blake Griffin", 30),\ - "Steve Nash": ("Steve Nash", 45),\ - "Jason Kidd": ("Jason Kidd", 45),\ - "Dirk Nowitzki": ("Dirk Nowitzki", 40),\ - "Paul George": ("Paul George", 28),\ - "Grant Hill": ("Grant Hill", 46),\ - "Shaquile O'Neal": ("Shaquile O'Neal", 47),\ - "JaVale McGee": ("JaVale McGee", 31),\ - "Dwight Howard": ("Dwight Howard", 33); - -INSERT\ - VERTEX bachelor(name, speciality)\ -VALUES\ - "Tim Duncan": ("Tim Duncan", "psychology"); - -INSERT\ - VERTEX team(name)\ -VALUES\ - "Nets": ("Nets"),\ - "Pistons": ("Pistons"),\ - "Bucks": ("Bucks"),\ - "Mavericks": ("Mavericks"),\ - "Clippers": ("Clippers"),\ - "Thunders": ("Thunders"),\ - "Lakers": ("Lakers"),\ - "Jazz": ("Jazz"),\ - "Nuggets": ("Nuggets"),\ - "Wizards": ("Wizards"),\ - "Pacers": ("Pacers"),\ - "Timberwolves": ("Timberwolves"),\ - "Hawks": ("Hawks"),\ - "Warriors": ("Warriors"),\ - "Magic": ("Magic"),\ - "Rockets": ("Rockets"),\ - "Pelicans": ("Pelicans"),\ - "Raptors": ("Raptors"),\ - "Spurs": ("Spurs"),\ - "Heat": ("Heat"),\ - "Grizzlies": ("Grizzlies"),\ - "Knicks": ("Knicks"),\ - "Suns": ("Suns"),\ - "Hornets": ("Hornets"),\ - "Cavaliers": ("Cavaliers"),\ - "Kings": ("Kings"),\ - "Celtics": ("Celtics"),\ - "76ers": ("76ers"),\ - "Trail Blazers": ("Trail Blazers"),\ - "Bulls": ("Bulls"); - -INSERT\ - EDGE serve(start_year, end_year)\ -VALUES\ - "Amar'e Stoudemire" -> "Suns": (2002, 2010),\ - "Amar'e Stoudemire" -> "Knicks": (2010, 2015),\ - "Amar'e Stoudemire" -> "Heat": (2015, 2016),\ - "Russell Westbrook" -> "Thunders": (2008, 2019),\ - "James Harden" -> "Thunders": (2009, 2012),\ - "James Harden" -> "Rockets": (2012, 2019),\ - "Kobe Bryant" -> "Lakers": (1996, 2016),\ - "Tracy McGrady" -> "Raptors": (1997, 2000),\ - "Tracy McGrady" -> "Magic": (2000, 2004),\ - "Tracy McGrady" -> "Rockets": (2004, 2010),\ - "Tracy McGrady" -> "Spurs": (2013, 2013),\ - "Chris Paul" -> "Hornets": (2005, 2011),\ - "Chris Paul" -> "Clippers": (2011, 2017),\ - "Chris Paul" -> "Rockets": (2017, 2021),\ - "Boris Diaw" -> "Hawks": (2003, 2005),\ - "Boris Diaw" -> "Suns": (2005, 2008),\ - "Boris Diaw" -> "Hornets": (2008, 2012),\ - "Boris Diaw" -> "Spurs": (2012, 2016),\ - "Boris Diaw" -> "Jazz": (2016, 2017),\ - "LeBron James" -> "Cavaliers": (2003, 2010),\ - "LeBron James" -> "Heat": (2010, 2014),\ - "LeBron James" -> "Cavaliers"@1: (2014, 2018),\ - "LeBron James" -> "Lakers": (2018, 2019),\ - "Klay Thompson" -> "Warriors": (2011, 2019),\ - "Kristaps Porzingis" -> "Knicks": (2015, 2019),\ - "Kristaps Porzingis" -> "Mavericks": (2019, 2020),\ - "Jonathon Simmons" -> "Spurs": (2015, 2017),\ - "Jonathon Simmons" -> "Magic": (2017, 2019),\ - "Jonathon Simmons" -> "76ers": (2019, 2019),\ - "Marco Belinelli" -> "Warriors": (2007, 2009),\ - "Marco Belinelli" -> "Raptors": (2009, 2010),\ - "Marco Belinelli" -> "Hornets": (2010, 2012),\ - "Marco Belinelli" -> "Bulls": (2012, 2013),\ - "Marco Belinelli" -> "Spurs": (2013, 2015),\ - "Marco Belinelli" -> "Kings": (2015, 2016),\ - "Marco Belinelli" -> "Hornets"@1: (2016, 2017),\ - "Marco Belinelli" -> "Hawks": (2017, 2018),\ - "Marco Belinelli" -> "76ers": (2018, 2018),\ - "Marco Belinelli" -> "Spurs"@1: (2018, 2019),\ - "Luka Doncic" -> "Mavericks": (2018, 2019),\ - "David West" -> "Hornets": (2003, 2011),\ - "David West" -> "Pacers": (2011, 2015),\ - "David West" -> "Spurs": (2015, 2016),\ - "David West" -> "Warriors": (2016, 2018),\ - "Tony Parker" -> "Spurs": (1999, 2018),\ - "Tony Parker" -> "Hornets": (2018, 2019),\ - "Danny Green" -> "Cavaliers": (2009, 2010),\ - "Danny Green" -> "Spurs": (2010, 2018),\ - "Danny Green" -> "Raptors": (2018, 2019),\ - "Rudy Gay" -> "Grizzlies": (2006, 2013),\ - "Rudy Gay" -> "Raptors": (2013, 2013),\ - "Rudy Gay" -> "Kings": (2013, 2017),\ - "Rudy Gay" -> "Spurs": (2017, 2019),\ - "LaMarcus Aldridge" -> "Trail Blazers": (2006, 2015),\ - "LaMarcus Aldridge" -> "Spurs": (2015, 2019),\ - "Tim Duncan" -> "Spurs": (1997, 2016),\ - "Kevin Durant" -> "Thunders": (2007, 2016),\ - "Kevin Durant" -> "Warriors": (2016, 2019),\ - "Stephen Curry" -> "Warriors": (2009, 2019),\ - "Ray Allen" -> "Bucks": (1996, 2003),\ - "Ray Allen" -> "Thunders": (2003, 2007),\ - "Ray Allen" -> "Celtics": (2007, 2012),\ - "Ray Allen" -> "Heat": (2012, 2014),\ - "Tiago Splitter" -> "Spurs": (2010, 2015),\ - "Tiago Splitter" -> "Hawks": (2015, 2017),\ - "Tiago Splitter" -> "76ers": (2017, 2017),\ - "DeAndre Jordan" -> "Clippers": (2008, 2018),\ - "DeAndre Jordan" -> "Mavericks": (2018, 2019),\ - "DeAndre Jordan" -> "Knicks": (2019, 2019),\ - "Paul Gasol" -> "Grizzlies": (2001, 2008),\ - "Paul Gasol" -> "Lakers": (2008, 2014),\ - "Paul Gasol" -> "Bulls": (2014, 2016),\ - "Paul Gasol" -> "Spurs": (2016, 2019),\ - "Paul Gasol" -> "Bucks": (2019, 2020),\ - "Aron Baynes" -> "Spurs": (2013, 2015),\ - "Aron Baynes" -> "Pistons": (2015, 2017),\ - "Aron Baynes" -> "Celtics": (2017, 2019),\ - "Cory Joseph" -> "Spurs": (2011, 2015),\ - "Cory Joseph" -> "Raptors": (2015, 2017),\ - "Cory Joseph" -> "Pacers": (2017, 2019),\ - "Vince Carter" -> "Raptors": (1998, 2004),\ - "Vince Carter" -> "Nets": (2004, 2009),\ - "Vince Carter" -> "Magic": (2009, 2010),\ - "Vince Carter" -> "Suns": (2010, 2011),\ - "Vince Carter" -> "Mavericks": (2011, 2014),\ - "Vince Carter" -> "Grizzlies": (2014, 2017),\ - "Vince Carter" -> "Kings": (2017, 2018),\ - "Vince Carter" -> "Hawks": (2018, 2019),\ - "Marc Gasol" -> "Grizzlies": (2008, 2019),\ - "Marc Gasol" -> "Raptors": (2019, 2019),\ - "Ricky Rubio" -> "Timberwolves": (2011, 2017),\ - "Ricky Rubio" -> "Jazz": (2017, 2019),\ - "Ben Simmons" -> "76ers": (2016, 2019),\ - "Giannis Antetokounmpo" -> "Bucks": (2013, 2019),\ - "Rajon Rondo" -> "Celtics": (2006, 2014),\ - "Rajon Rondo" -> "Mavericks": (2014, 2015),\ - "Rajon Rondo" -> "Kings": (2015, 2016),\ - "Rajon Rondo" -> "Bulls": (2016, 2017),\ - "Rajon Rondo" -> "Pelicans": (2017, 2018),\ - "Rajon Rondo" -> "Lakers": (2018, 2019),\ - "Manu Ginobili" -> "Spurs": (2002, 2018),\ - "Kyrie Irving" -> "Cavaliers": (2011, 2017),\ - "Kyrie Irving" -> "Celtics": (2017, 2019),\ - "Carmelo Anthony" -> "Nuggets": (2003, 2011),\ - "Carmelo Anthony" -> "Knicks": (2011, 2017),\ - "Carmelo Anthony" -> "Thunders": (2017, 2018),\ - "Carmelo Anthony" -> "Rockets": (2018, 2019),\ - "Dwyane Wade" -> "Heat": (2003, 2016),\ - "Dwyane Wade" -> "Bulls": (2016, 2017),\ - "Dwyane Wade" -> "Cavaliers": (2017, 2018),\ - "Dwyane Wade" -> "Heat"@1: (2018, 2019),\ - "Joel Embiid" -> "76ers": (2014, 2019),\ - "Damian Lillard" -> "Trail Blazers": (2012, 2019),\ - "Yao Ming" -> "Rockets": (2002, 2011),\ - "Kyle Anderson" -> "Spurs": (2014, 2018),\ - "Kyle Anderson" -> "Grizzlies": (2018, 2019),\ - "Dejounte Murray" -> "Spurs": (2016, 2019),\ - "Blake Griffin" -> "Clippers": (2009, 2018),\ - "Blake Griffin" -> "Pistons": (2018, 2019),\ - "Steve Nash" -> "Suns": (1996, 1998),\ - "Steve Nash" -> "Mavericks": (1998, 2004),\ - "Steve Nash" -> "Suns"@1: (2004, 2012),\ - "Steve Nash" -> "Lakers": (2012, 2015),\ - "Jason Kidd" -> "Mavericks": (1994, 1996),\ - "Jason Kidd" -> "Suns": (1996, 2001),\ - "Jason Kidd" -> "Nets": (2001, 2008),\ - "Jason Kidd" -> "Mavericks"@1: (2008, 2012),\ - "Jason Kidd" -> "Knicks": (2012, 2013),\ - "Dirk Nowitzki" -> "Mavericks": (1998, 2019),\ - "Paul George" -> "Pacers": (2010, 2017),\ - "Paul George" -> "Thunders": (2017, 2019),\ - "Grant Hill" -> "Pistons": (1994, 2000),\ - "Grant Hill" -> "Magic": (2000, 2007),\ - "Grant Hill" -> "Suns": (2007, 2012),\ - "Grant Hill" -> "Clippers": (2012, 2013),\ - "Shaquile O'Neal" -> "Magic": (1992, 1996),\ - "Shaquile O'Neal" -> "Lakers": (1996, 2004),\ - "Shaquile O'Neal" -> "Heat": (2004, 2008),\ - "Shaquile O'Neal" -> "Suns": (2008, 2009),\ - "Shaquile O'Neal" -> "Cavaliers": (2009, 2010),\ - "Shaquile O'Neal" -> "Celtics": (2010, 2011),\ - "JaVale McGee" -> "Wizards": (2008, 2012),\ - "JaVale McGee" -> "Nuggets": (2012, 2015),\ - "JaVale McGee" -> "Mavericks": (2015, 2016),\ - "JaVale McGee" -> "Warriors": (2016, 2018),\ - "JaVale McGee" -> "Lakers": (2018, 2019),\ - "Dwight Howard" -> "Magic": (2004, 2012),\ - "Dwight Howard" -> "Lakers": (2012, 2013),\ - "Dwight Howard" -> "Rockets": (2013, 2016),\ - "Dwight Howard" -> "Hawks": (2016, 2017),\ - "Dwight Howard" -> "Hornets": (2017, 2018),\ - "Dwight Howard" -> "Wizards": (2018, 2019); - -INSERT\ - EDGE like(likeness)\ -VALUES\ - "Amar'e Stoudemire" -> "Steve Nash": (90),\ - "Russell Westbrook" -> "Paul George": (90),\ - "Russell Westbrook" -> "James Harden": (90),\ - "James Harden" -> "Russell Westbrook": (80),\ - "Tracy McGrady" -> "Kobe Bryant": (90),\ - "Tracy McGrady" -> "Grant Hill": (90),\ - "Tracy McGrady" -> "Rudy Gay": (90),\ - "Chris Paul" -> "LeBron James": (90),\ - "Chris Paul" -> "Carmelo Anthony": (90),\ - "Chris Paul" -> "Dwyane Wade": (90),\ - "Boris Diaw" -> "Tony Parker": (80),\ - "Boris Diaw" -> "Tim Duncan": (80),\ - "LeBron James" -> "Ray Allen": (100),\ - "Klay Thompson" -> "Stephen Curry": (90),\ - "Kristaps Porzingis" -> "Luka Doncic": (90),\ - "Marco Belinelli" -> "Tony Parker": (50),\ - "Marco Belinelli" -> "Tim Duncan": (55),\ - "Marco Belinelli" -> "Danny Green": (60),\ - "Luka Doncic" -> "Dirk Nowitzki": (90),\ - "Luka Doncic" -> "Kristaps Porzingis": (90),\ - "Luka Doncic" -> "James Harden": (80),\ - "Tony Parker" -> "Tim Duncan": (95),\ - "Tony Parker" -> "Manu Ginobili": (95),\ - "Tony Parker" -> "LaMarcus Aldridge": (90),\ - "Danny Green" -> "Marco Belinelli": (83),\ - "Danny Green" -> "Tim Duncan": (70),\ - "Danny Green" -> "LeBron James": (80),\ - "Rudy Gay" -> "LaMarcus Aldridge": (70),\ - "LaMarcus Aldridge" -> "Tony Parker": (75),\ - "LaMarcus Aldridge" -> "Tim Duncan": (75),\ - "Tim Duncan" -> "Tony Parker": (95),\ - "Tim Duncan" -> "Manu Ginobili": (95),\ - "Ray Allen" -> "Rajon Rondo": (9),\ - "Tiago Splitter" -> "Tim Duncan": (80),\ - "Tiago Splitter" -> "Manu Ginobili": (90),\ - "Paul Gasol" -> "Kobe Bryant": (90),\ - "Paul Gasol" -> "Marc Gasol": (99),\ - "Aron Baynes" -> "Tim Duncan": (80),\ - "Vince Carter" -> "Tracy McGrady": (90),\ - "Vince Carter" -> "Jason Kidd": (70),\ - "Marc Gasol" -> "Paul Gasol": (99),\ - "Ben Simmons" -> "Joel Embiid": (80),\ - "Rajon Rondo" -> "Ray Allen": (-1),\ - "Manu Ginobili" -> "Tim Duncan": (90),\ - "Kyrie Irving" -> "LeBron James": (13),\ - "Carmelo Anthony" -> "LeBron James": (90),\ - "Carmelo Anthony" -> "Chris Paul": (90),\ - "Carmelo Anthony" -> "Dwyane Wade": (90),\ - "Dwyane Wade" -> "LeBron James": (90),\ - "Dwyane Wade" -> "Chris Paul": (90),\ - "Dwyane Wade" -> "Carmelo Anthony": (90),\ - "Joel Embiid" -> "Ben Simmons": (80),\ - "Damian Lillard" -> "LaMarcus Aldridge": (80),\ - "Yao Ming" -> "Tracy McGrady": (90),\ - "Yao Ming" -> "Shaquile O'Neal": (90),\ - "Dejounte Murray" -> "Tim Duncan": (99),\ - "Dejounte Murray" -> "Tony Parker": (99),\ - "Dejounte Murray" -> "Manu Ginobili": (99),\ - "Dejounte Murray" -> "Marco Belinelli": (99),\ - "Dejounte Murray" -> "Danny Green": (99),\ - "Dejounte Murray" -> "LeBron James": (99),\ - "Dejounte Murray" -> "Russell Westbrook": (99),\ - "Dejounte Murray" -> "Chris Paul": (99),\ - "Dejounte Murray" -> "Kyle Anderson": (99),\ - "Dejounte Murray" -> "Kevin Durant": (99),\ - "Dejounte Murray" -> "James Harden": (99),\ - "Dejounte Murray" -> "Tony Parker": (99),\ - "Blake Griffin" -> "Chris Paul": (-1),\ - "Steve Nash" -> "Amar'e Stoudemire": (90),\ - "Steve Nash" -> "Dirk Nowitzki": (88),\ - "Steve Nash" -> "Stephen Curry": (90),\ - "Steve Nash" -> "Jason Kidd": (85),\ - "Jason Kidd" -> "Vince Carter": (80),\ - "Jason Kidd" -> "Steve Nash": (90),\ - "Jason Kidd" -> "Dirk Nowitzki": (85),\ - "Dirk Nowitzki" -> "Steve Nash": (80),\ - "Dirk Nowitzki" -> "Jason Kidd": (80),\ - "Dirk Nowitzki" -> "Dwyane Wade": (10),\ - "Paul George" -> "Russell Westbrook": (95),\ - "Grant Hill" -> "Tracy McGrady": (90),\ - "Shaquile O'Neal" -> "JaVale McGee": (100),\ - "Shaquile O'Neal" -> "Tim Duncan": (80); - -INSERT\ - EDGE teammate(start_year, end_year)\ -VALUES\ - "Tony Parker" -> "Tim Duncan": (2001, 2016),\ - "Tony Parker" -> "Manu Ginobili": (2002, 2018),\ - "Tony Parker" -> "LaMarcus Aldridge": (2015, 2018),\ - "Tony Parker" -> "Kyle Anderson": (2014, 2016),\ - "Tim Duncan" -> "Tony Parker": (2001, 2016),\ - "Tim Duncan" -> "Manu Ginobili": (2002, 2016),\ - "Tim Duncan" -> "LaMarcus Aldridge": (2015, 2016),\ - "Tim Duncan" -> "Danny Green": (2010, 2016),\ - "Manu Ginobili" -> "Tim Duncan": (2002, 2016),\ - "Manu Ginobili" -> "Tony Parker": (2002, 2016); +create space basketballplayer(partition_num=10,replica_factor=1,vid_type=fixed_string(32)); +:sleep 20 +use basketballplayer; +create tag player(name string,age int); +create tag team(name string); +create edge serve(start_year int,end_year int); +create edge follow(degree int); +:sleep 20 +create tag index player_index_0 on player(); +create tag index player_index_1 on player(name(20)); +:sleep 20 +insert vertex player(name,age) values "player100":("Tim Duncan", 42); +insert vertex player(name,age) values "player101":("Tony Parker", 36); +insert vertex player(name,age) values "player102":("LaMarcus Aldridge", 33); +insert vertex player(name,age) values "player103":("Rudy Gay", 32); +insert vertex player(name,age) values "player104":("Marco Belinelli", 32); +insert vertex player(name,age) values "player105":("Danny Green", 31); +insert vertex player(name,age) values "player106":("Kyle Anderson", 25); +insert vertex player(name,age) values "player107":("Aron Baynes", 32); +insert vertex player(name,age) values "player108":("Boris Diaw", 36); +insert vertex player(name,age) values "player109":("Tiago Splitter", 34); +insert vertex player(name,age) values "player110":("Cory Joseph", 27); +insert vertex player(name,age) values "player111":("David West", 38); +insert vertex player(name,age) values "player112":("Jonathon Simmons", 29); +insert vertex player(name,age) values "player113":("Dejounte Murray", 29); +insert vertex player(name,age) values "player114":("Tracy McGrady", 39); +insert vertex player(name,age) values "player115":("Kobe Bryant", 40); +insert vertex player(name,age) values "player116":("LeBron James", 34); +insert vertex player(name,age) values "player117":("Stephen Curry", 31); +insert vertex player(name,age) values "player118":("Russell Westbrook", 30); +insert vertex player(name,age) values "player119":("Kevin Durant", 30); +insert vertex player(name,age) values "player120":("James Harden", 29); +insert vertex player(name,age) values "player121":("Chris Paul", 33); +insert vertex player(name,age) values "player122":("DeAndre Jordan", 30); +insert vertex player(name,age) values "player123":("Ricky Rubio", 28); +insert vertex player(name,age) values "player124":("Rajon Rondo", 33); +insert vertex player(name,age) values "player125":("Manu Ginobili", 41); +insert vertex player(name,age) values "player126":("Kyrie Irving", 26); +insert vertex player(name,age) values "player127":("Vince Carter", 42); +insert vertex player(name,age) values "player128":("Carmelo Anthony", 34); +insert vertex player(name,age) values "player129":("Dwyane Wade", 37); +insert vertex player(name,age) values "player130":("Joel Embiid", 25); +insert vertex player(name,age) values "player131":("Paul George", 28); +insert vertex player(name,age) values "player132":("Giannis Antetokounmpo", 24); +insert vertex player(name,age) values "player133":("Yao Ming", 38); +insert vertex player(name,age) values "player134":("Blake Griffin", 30); +insert vertex player(name,age) values "player135":("Damian Lillard", 28); +insert vertex player(name,age) values "player136":("Steve Nash", 45); +insert vertex player(name,age) values "player137":("Dirk Nowitzki", 40); +insert vertex player(name,age) values "player138":("Paul Gasol", 38); +insert vertex player(name,age) values "player139":("Marc Gasol", 34); +insert vertex player(name,age) values "player140":("Grant Hill", 46); +insert vertex player(name,age) values "player141":("Ray Allen", 43); +insert vertex player(name,age) values "player142":("Klay Thompson", 29); +insert vertex player(name,age) values "player143":("Kristaps Porzingis", 23); +insert vertex player(name,age) values "player144":("Shaquille O'Neal", 47); +insert vertex player(name,age) values "player145":("JaVale McGee", 31); +insert vertex player(name,age) values "player146":("Dwight Howard", 33); +insert vertex player(name,age) values "player147":("Amar'e Stoudemire", 36); +insert vertex player(name,age) values "player148":("Jason Kidd", 45); +insert vertex player(name,age) values "player149":("Ben Simmons", 22); +insert vertex player(name,age) values "player150":("Luka Doncic", 20); +insert vertex team(name) values "team200":("Warriors"); +insert vertex team(name) values "team201":("Nuggets"); +insert vertex team(name) values "team202":("Rockets"); +insert vertex team(name) values "team203":("Trail Blazers"); +insert vertex team(name) values "team204":("Spurs"); +insert vertex team(name) values "team205":("Thunders"); +insert vertex team(name) values "team206":("Jazz"); +insert vertex team(name) values "team207":("Clippers"); +insert vertex team(name) values "team208":("Kings"); +insert vertex team(name) values "team209":("Timberwolves"); +insert vertex team(name) values "team210":("Lakers"); +insert vertex team(name) values "team211":("Pelicans"); +insert vertex team(name) values "team212":("Grizzlies"); +insert vertex team(name) values "team213":("Mavericks"); +insert vertex team(name) values "team214":("Suns"); +insert vertex team(name) values "team215":("Hornets"); +insert vertex team(name) values "team216":("Cavaliers"); +insert vertex team(name) values "team217":("Celtics"); +insert vertex team(name) values "team218":("Raptors"); +insert vertex team(name) values "team219":("76ers"); +insert vertex team(name) values "team220":("Pacers"); +insert vertex team(name) values "team221":("Bulls"); +insert vertex team(name) values "team222":("Hawks"); +insert vertex team(name) values "team223":("Knicks"); +insert vertex team(name) values "team224":("Pistons"); +insert vertex team(name) values "team225":("Bucks"); +insert vertex team(name) values "team226":("Magic"); +insert vertex team(name) values "team227":("Nets"); +insert vertex team(name) values "team228":("Wizards"); +insert vertex team(name) values "team229":("Heat"); +insert edge follow(degree) values "player100"->"player101":(95); +insert edge follow(degree) values "player100"->"player125":(95); +insert edge follow(degree) values "player101"->"player100":(95); +insert edge follow(degree) values "player101"->"player125":(95); +insert edge follow(degree) values "player101"->"player102":(90); +insert edge follow(degree) values "player125"->"player100":(90); +insert edge follow(degree) values "player102"->"player101":(75); +insert edge follow(degree) values "player102"->"player100":(75); +insert edge follow(degree) values "player103"->"player102":(70); +insert edge follow(degree) values "player104"->"player101":(50); +insert edge follow(degree) values "player104"->"player100":(55); +insert edge follow(degree) values "player104"->"player105":(60); +insert edge follow(degree) values "player105"->"player104":(83); +insert edge follow(degree) values "player105"->"player100":(70); +insert edge follow(degree) values "player105"->"player116":(80); +insert edge follow(degree) values "player107"->"player100":(80); +insert edge follow(degree) values "player108"->"player101":(80); +insert edge follow(degree) values "player108"->"player100":(80); +insert edge follow(degree) values "player109"->"player100":(80); +insert edge follow(degree) values "player109"->"player125":(90); +insert edge follow(degree) values "player113"->"player100":(99); +insert edge follow(degree) values "player113"->"player101":(99); +insert edge follow(degree) values "player113"->"player125":(99); +insert edge follow(degree) values "player113"->"player104":(99); +insert edge follow(degree) values "player113"->"player105":(99); +insert edge follow(degree) values "player113"->"player116":(99); +insert edge follow(degree) values "player113"->"player118":(99); +insert edge follow(degree) values "player113"->"player121":(99); +insert edge follow(degree) values "player113"->"player106":(99); +insert edge follow(degree) values "player113"->"player119":(99); +insert edge follow(degree) values "player113"->"player120":(99); +insert edge follow(degree) values "player114"->"player115":(90); +insert edge follow(degree) values "player114"->"player140":(90); +insert edge follow(degree) values "player114"->"player103":(90); +insert edge follow(degree) values "player116"->"player141":(100); +insert edge follow(degree) values "player118"->"player131":(90); +insert edge follow(degree) values "player118"->"player120":(90); +insert edge follow(degree) values "player120"->"player118":(80); +insert edge follow(degree) values "player121"->"player116":(90); +insert edge follow(degree) values "player121"->"player128":(90); +insert edge follow(degree) values "player121"->"player129":(90); +insert edge follow(degree) values "player124"->"player141":(-1); +insert edge follow(degree) values "player126"->"player116":(13); +insert edge follow(degree) values "player127"->"player114":(90); +insert edge follow(degree) values "player127"->"player148":(70); +insert edge follow(degree) values "player128"->"player116":(90); +insert edge follow(degree) values "player128"->"player121":(90); +insert edge follow(degree) values "player128"->"player129":(90); +insert edge follow(degree) values "player129"->"player116":(90); +insert edge follow(degree) values "player129"->"player121":(90); +insert edge follow(degree) values "player129"->"player128":(90); +insert edge follow(degree) values "player130"->"player149":(80); +insert edge follow(degree) values "player131"->"player118":(95); +insert edge follow(degree) values "player133"->"player114":(90); +insert edge follow(degree) values "player133"->"player144":(90); +insert edge follow(degree) values "player134"->"player121":(-1); +insert edge follow(degree) values "player135"->"player102":(80); +insert edge follow(degree) values "player136"->"player147":(90); +insert edge follow(degree) values "player136"->"player137":(88); +insert edge follow(degree) values "player136"->"player117":(90); +insert edge follow(degree) values "player136"->"player148":(85); +insert edge follow(degree) values "player137"->"player136":(80); +insert edge follow(degree) values "player137"->"player148":(80); +insert edge follow(degree) values "player137"->"player129":(10); +insert edge follow(degree) values "player138"->"player115":(90); +insert edge follow(degree) values "player138"->"player139":(99); +insert edge follow(degree) values "player139"->"player138":(99); +insert edge follow(degree) values "player140"->"player114":(90); +insert edge follow(degree) values "player141"->"player124":(9); +insert edge follow(degree) values "player142"->"player117":(90); +insert edge follow(degree) values "player143"->"player150":(90); +insert edge follow(degree) values "player144"->"player145":(100); +insert edge follow(degree) values "player144"->"player100":(80); +insert edge follow(degree) values "player147"->"player136":(90); +insert edge follow(degree) values "player148"->"player127":(80); +insert edge follow(degree) values "player148"->"player136":(90); +insert edge follow(degree) values "player148"->"player137":(85); +insert edge follow(degree) values "player149"->"player130":(80); +insert edge follow(degree) values "player150"->"player137":(90); +insert edge follow(degree) values "player150"->"player143":(90); +insert edge follow(degree) values "player150"->"player120":(80); +insert edge serve(start_year,end_year) values "player100"->"team204":(1997, 2016); +insert edge serve(start_year,end_year) values "player101"->"team204":(1999, 2018); +insert edge serve(start_year,end_year) values "player101"->"team215":(2018, 2019); +insert edge serve(start_year,end_year) values "player102"->"team203":(2006, 2015); +insert edge serve(start_year,end_year) values "player102"->"team204":(2015, 2019); +insert edge serve(start_year,end_year) values "player103"->"team212":(2006, 2013); +insert edge serve(start_year,end_year) values "player103"->"team218":(2013, 2013); +insert edge serve(start_year,end_year) values "player103"->"team208":(2013, 2017); +insert edge serve(start_year,end_year) values "player103"->"team204":(2017, 2019); +insert edge serve(start_year,end_year) values "player104"->"team200":(2007, 2009); +insert edge serve(start_year,end_year) values "player104"->"team218":(2009, 2010); +insert edge serve(start_year,end_year) values "player104"->"team215"@20102012:(2010, 2012); +insert edge serve(start_year,end_year) values "player104"->"team221":(2012, 2013); +insert edge serve(start_year,end_year) values "player104"->"team204"@20132015:(2013, 2015); +insert edge serve(start_year,end_year) values "player104"->"team208":(2015, 2016); +insert edge serve(start_year,end_year) values "player104"->"team215"@20162017:(2016, 2017); +insert edge serve(start_year,end_year) values "player104"->"team222":(2017, 2018); +insert edge serve(start_year,end_year) values "player104"->"team219":(2018, 2018); +insert edge serve(start_year,end_year) values "player104"->"team204"@20182019:(2018, 2019); +insert edge serve(start_year,end_year) values "player105"->"team216":(2009, 2010); +insert edge serve(start_year,end_year) values "player105"->"team204":(2010, 2018); +insert edge serve(start_year,end_year) values "player105"->"team218":(2018, 2019); +insert edge serve(start_year,end_year) values "player106"->"team204":(2014, 2018); +insert edge serve(start_year,end_year) values "player106"->"team212":(2018, 2019); +insert edge serve(start_year,end_year) values "player107"->"team204":(2013, 2015); +insert edge serve(start_year,end_year) values "player107"->"team224":(2015, 2017); +insert edge serve(start_year,end_year) values "player107"->"team217":(2017, 2019); +insert edge serve(start_year,end_year) values "player108"->"team222":(2003, 2005); +insert edge serve(start_year,end_year) values "player108"->"team214":(2005, 2008); +insert edge serve(start_year,end_year) values "player108"->"team215":(2008, 2012); +insert edge serve(start_year,end_year) values "player108"->"team204":(2012, 2016); +insert edge serve(start_year,end_year) values "player108"->"team206":(2016, 2017); +insert edge serve(start_year,end_year) values "player109"->"team204":(2010, 2015); +insert edge serve(start_year,end_year) values "player109"->"team222":(2015, 2017); +insert edge serve(start_year,end_year) values "player109"->"team219":(2017, 2017); +insert edge serve(start_year,end_year) values "player110"->"team204":(2011, 2015); +insert edge serve(start_year,end_year) values "player110"->"team218":(2015, 2017); +insert edge serve(start_year,end_year) values "player110"->"team220":(2017, 2019); +insert edge serve(start_year,end_year) values "player111"->"team215":(2003, 2011); +insert edge serve(start_year,end_year) values "player111"->"team220":(2011, 2015); +insert edge serve(start_year,end_year) values "player111"->"team204":(2015, 2016); +insert edge serve(start_year,end_year) values "player111"->"team200":(2016, 2018); +insert edge serve(start_year,end_year) values "player112"->"team204":(2015, 2017); +insert edge serve(start_year,end_year) values "player112"->"team226":(2017, 2019); +insert edge serve(start_year,end_year) values "player112"->"team219":(2019, 2019); +insert edge serve(start_year,end_year) values "player113"->"team204":(2016, 2019); +insert edge serve(start_year,end_year) values "player114"->"team218":(1997, 2000); +insert edge serve(start_year,end_year) values "player114"->"team226":(2000, 2004); +insert edge serve(start_year,end_year) values "player114"->"team202":(2004, 2010); +insert edge serve(start_year,end_year) values "player114"->"team204":(2013, 2013); +insert edge serve(start_year,end_year) values "player115"->"team210":(1996, 2016); +insert edge serve(start_year,end_year) values "player116"->"team216"@20032010:(2003, 2010); +insert edge serve(start_year,end_year) values "player116"->"team229":(2010, 2014); +insert edge serve(start_year,end_year) values "player116"->"team216"@20142018:(2014, 2018); +insert edge serve(start_year,end_year) values "player116"->"team210":(2018, 2019); +insert edge serve(start_year,end_year) values "player117"->"team200":(2009, 2019);; +insert edge serve(start_year,end_year) values "player118"->"team205":(2008, 2019); +insert edge serve(start_year,end_year) values "player119"->"team205":(2007, 2016); +insert edge serve(start_year,end_year) values "player119"->"team200":(2016, 2019); +insert edge serve(start_year,end_year) values "player120"->"team205":(2009, 2012); +insert edge serve(start_year,end_year) values "player120"->"team202":(2012, 2019); +insert edge serve(start_year,end_year) values "player121"->"team215":(2005, 2011); +insert edge serve(start_year,end_year) values "player121"->"team207":(2011, 2017); +insert edge serve(start_year,end_year) values "player121"->"team202":(2017, 2021); +insert edge serve(start_year,end_year) values "player122"->"team207":(2008, 2018); +insert edge serve(start_year,end_year) values "player122"->"team213":(2018, 2019); +insert edge serve(start_year,end_year) values "player122"->"team223":(2019, 2019); +insert edge serve(start_year,end_year) values "player123"->"team209":(2011, 2017); +insert edge serve(start_year,end_year) values "player123"->"team206":(2017, 2019); +insert edge serve(start_year,end_year) values "player124"->"team217":(2006, 2014); +insert edge serve(start_year,end_year) values "player124"->"team213":(2014, 2015); +insert edge serve(start_year,end_year) values "player124"->"team208":(2015, 2016); +insert edge serve(start_year,end_year) values "player124"->"team221":(2016, 2017); +insert edge serve(start_year,end_year) values "player124"->"team211":(2017, 2018); +insert edge serve(start_year,end_year) values "player124"->"team210":(2018, 2019); +insert edge serve(start_year,end_year) values "player125"->"team204":(2002, 2018); +insert edge serve(start_year,end_year) values "player126"->"team216":(2011, 2017); +insert edge serve(start_year,end_year) values "player126"->"team217":(2017, 2019); +insert edge serve(start_year,end_year) values "player127"->"team218":(1998, 2004); +insert edge serve(start_year,end_year) values "player127"->"team227":(2004, 2009); +insert edge serve(start_year,end_year) values "player127"->"team226":(2009, 2010); +insert edge serve(start_year,end_year) values "player127"->"team214":(2010, 2011); +insert edge serve(start_year,end_year) values "player127"->"team213":(2011, 2014); +insert edge serve(start_year,end_year) values "player127"->"team212":(2014, 2017); +insert edge serve(start_year,end_year) values "player127"->"team208":(2017, 2018); +insert edge serve(start_year,end_year) values "player127"->"team222":(2018, 2019); +insert edge serve(start_year,end_year) values "player128"->"team201":(2003, 2011); +insert edge serve(start_year,end_year) values "player128"->"team223":(2011, 2017); +insert edge serve(start_year,end_year) values "player128"->"team205":(2017, 2018); +insert edge serve(start_year,end_year) values "player128"->"team202":(2018, 2019); +insert edge serve(start_year,end_year) values "player129"->"team229"@20032016:(2003, 2016); +insert edge serve(start_year,end_year) values "player129"->"team221":(2016, 2017); +insert edge serve(start_year,end_year) values "player129"->"team216":(2017, 2018); +insert edge serve(start_year,end_year) values "player129"->"team229"@20182019:(2018, 2019); +insert edge serve(start_year,end_year) values "player130"->"team219":(2014, 2019); +insert edge serve(start_year,end_year) values "player131"->"team220":(2010, 2017); +insert edge serve(start_year,end_year) values "player131"->"team205":(2017, 2019); +insert edge serve(start_year,end_year) values "player132"->"team225":(2013, 2019); +insert edge serve(start_year,end_year) values "player133"->"team202":(2002, 2011); +insert edge serve(start_year,end_year) values "player134"->"team207":(2009, 2018); +insert edge serve(start_year,end_year) values "player134"->"team224":(2018, 2019); +insert edge serve(start_year,end_year) values "player135"->"team203":(2012, 2019); +insert edge serve(start_year,end_year) values "player136"->"team214"@19961998:(1996, 1998); +insert edge serve(start_year,end_year) values "player136"->"team213":(1998, 2004); +insert edge serve(start_year,end_year) values "player136"->"team214"@20042012:(2004, 2012); +insert edge serve(start_year,end_year) values "player136"->"team210":(2012, 2015); +insert edge serve(start_year,end_year) values "player137"->"team213":(1998, 2019); +insert edge serve(start_year,end_year) values "player138"->"team212":(2001, 2008); +insert edge serve(start_year,end_year) values "player138"->"team210":(2008, 2014); +insert edge serve(start_year,end_year) values "player138"->"team221":(2014, 2016); +insert edge serve(start_year,end_year) values "player138"->"team204":(2016, 2019); +insert edge serve(start_year,end_year) values "player138"->"team225":(2019, 2020); +insert edge serve(start_year,end_year) values "player139"->"team212":(2008, 2019); +insert edge serve(start_year,end_year) values "player139"->"team218":(2019, 2019); +insert edge serve(start_year,end_year) values "player140"->"team224":(1994, 2000); +insert edge serve(start_year,end_year) values "player140"->"team226":(2000, 2007); +insert edge serve(start_year,end_year) values "player140"->"team214":(2007, 2012); +insert edge serve(start_year,end_year) values "player140"->"team207":(2012, 2013); +insert edge serve(start_year,end_year) values "player141"->"team225":(1996, 2003); +insert edge serve(start_year,end_year) values "player141"->"team205":(2003, 2007); +insert edge serve(start_year,end_year) values "player141"->"team217":(2007, 2012); +insert edge serve(start_year,end_year) values "player141"->"team229":(2012, 2014); +insert edge serve(start_year,end_year) values "player142"->"team200":(2011, 2019); +insert edge serve(start_year,end_year) values "player143"->"team223":(2015, 2019); +insert edge serve(start_year,end_year) values "player143"->"team213":(2019, 2020); +insert edge serve(start_year,end_year) values "player144"->"team226":(1992, 1996); +insert edge serve(start_year,end_year) values "player144"->"team210":(1996, 2004); +insert edge serve(start_year,end_year) values "player144"->"team229":(2004, 2008); +insert edge serve(start_year,end_year) values "player144"->"team214":(2008, 2009); +insert edge serve(start_year,end_year) values "player144"->"team216":(2009, 2010); +insert edge serve(start_year,end_year) values "player144"->"team217":(2010, 2011); +insert edge serve(start_year,end_year) values "player145"->"team228":(2008, 2012); +insert edge serve(start_year,end_year) values "player145"->"team201":(2012, 2015); +insert edge serve(start_year,end_year) values "player145"->"team213":(2015, 2016); +insert edge serve(start_year,end_year) values "player145"->"team200":(2016, 2018); +insert edge serve(start_year,end_year) values "player145"->"team210":(2018, 2019); +insert edge serve(start_year,end_year) values "player146"->"team226":(2004, 2012); +insert edge serve(start_year,end_year) values "player146"->"team210":(2012, 2013); +insert edge serve(start_year,end_year) values "player146"->"team202":(2013, 2016); +insert edge serve(start_year,end_year) values "player146"->"team222":(2016, 2017); +insert edge serve(start_year,end_year) values "player146"->"team215":(2017, 2018); +insert edge serve(start_year,end_year) values "player146"->"team228":(2018, 2019); +insert edge serve(start_year,end_year) values "player147"->"team214":(2002, 2010); +insert edge serve(start_year,end_year) values "player147"->"team223":(2010, 2015); +insert edge serve(start_year,end_year) values "player147"->"team229":(2015, 2016); +insert edge serve(start_year,end_year) values "player148"->"team213"@19941996:(1994, 1996); +insert edge serve(start_year,end_year) values "player148"->"team214":(1996, 2001); +insert edge serve(start_year,end_year) values "player148"->"team227":(2001, 2008); +insert edge serve(start_year,end_year) values "player148"->"team213"@20082012:(2008, 2012); +insert edge serve(start_year,end_year) values "player148"->"team223":(2012, 2013); +insert edge serve(start_year,end_year) values "player149"->"team219":(2016, 2019); +insert edge serve(start_year,end_year) values "player150"->"team213":(2018, 2019); diff --git a/data/nba.ngql b/data/nba.ngql new file mode 100644 index 0000000..7612674 --- /dev/null +++ b/data/nba.ngql @@ -0,0 +1,384 @@ +CREATE SPACE nba(VID_TYPE=FIXED_STRING(32));USE nba; + +CREATE TAG IF NOT EXISTS player(name string, age int);\ + +CREATE TAG IF NOT EXISTS team(name string);\ + +CREATE TAG IF NOT EXISTS bachelor(name string, speciality string);\ + +CREATE EDGE IF NOT EXISTS like(likeness int);\ + +CREATE EDGE IF NOT EXISTS serve(start_year int, end_year int);\ + +CREATE EDGE IF NOT EXISTS teammate(start_year int, end_year int);\ + +CREATE TAG INDEX IF NOT EXISTS player_name_index ON player(name(64));\ + +CREATE TAG INDEX IF NOT EXISTS player_age_index ON player(age);\ + +CREATE TAG INDEX IF NOT EXISTS team_name_index ON team(name(64));\ + +CREATE EDGE INDEX IF NOT EXISTS like_index ON like(likeness);\ + +CREATE EDGE INDEX IF NOT EXISTS serve_index1 ON serve(start_year);\ + +CREATE EDGE INDEX IF NOT EXISTS serve_index2 ON serve(end_year);\ + +CREATE EDGE INDEX IF NOT EXISTS teammate_index1 ON teammate(start_year);\ + +CREATE EDGE INDEX IF NOT EXISTS teammate_index2 ON teammate(end_year);\ + +:sleep 10 + +INSERT VERTEX player(name, age) VALUES\ + "Null1": (null, -1),\ + "Null2": (null, -2),\ + "Null3": (null, -3),\ + "Null4": (null, -4),\ + "Nobody": ("Nobody", 0),\ + "Amar'e Stoudemire": ("Amar'e Stoudemire", 36),\ + "Russell Westbrook": ("Russell Westbrook", 30),\ + "James Harden": ("James Harden", 29),\ + "Kobe Bryant": ("Kobe Bryant", 40),\ + "Tracy McGrady": ("Tracy McGrady", 39),\ + "Chris Paul": ("Chris Paul", 33),\ + "Boris Diaw": ("Boris Diaw", 36),\ + "LeBron James": ("LeBron James", 34),\ + "Klay Thompson": ("Klay Thompson", 29),\ + "Kristaps Porzingis": ("Kristaps Porzingis", 23),\ + "Jonathon Simmons": ("Jonathon Simmons", 29),\ + "Marco Belinelli": ("Marco Belinelli", 32),\ + "Luka Doncic": ("Luka Doncic", 20),\ + "David West": ("David West", 38),\ + "Tony Parker": ("Tony Parker", 36),\ + "Danny Green": ("Danny Green", 31),\ + "Rudy Gay": ("Rudy Gay", 32),\ + "LaMarcus Aldridge": ("LaMarcus Aldridge", 33),\ + "Tim Duncan": ("Tim Duncan", 42),\ + "Kevin Durant": ("Kevin Durant", 30),\ + "Stephen Curry": ("Stephen Curry", 31),\ + "Ray Allen": ("Ray Allen", 43),\ + "Tiago Splitter": ("Tiago Splitter", 34),\ + "DeAndre Jordan": ("DeAndre Jordan", 30),\ + "Paul Gasol": ("Paul Gasol", 38),\ + "Aron Baynes": ("Aron Baynes", 32),\ + "Cory Joseph": ("Cory Joseph", 27),\ + "Vince Carter": ("Vince Carter", 42),\ + "Marc Gasol": ("Marc Gasol", 34),\ + "Ricky Rubio": ("Ricky Rubio", 28),\ + "Ben Simmons": ("Ben Simmons", 22),\ + "Giannis Antetokounmpo": ("Giannis Antetokounmpo", 24),\ + "Rajon Rondo": ("Rajon Rondo", 33),\ + "Manu Ginobili": ("Manu Ginobili", 41),\ + "Kyrie Irving": ("Kyrie Irving", 26),\ + "Carmelo Anthony": ("Carmelo Anthony", 34),\ + "Dwyane Wade": ("Dwyane Wade", 37),\ + "Joel Embiid": ("Joel Embiid", 25),\ + "Damian Lillard": ("Damian Lillard", 28),\ + "Yao Ming": ("Yao Ming", 38),\ + "Kyle Anderson": ("Kyle Anderson", 25),\ + "Dejounte Murray": ("Dejounte Murray", 29),\ + "Blake Griffin": ("Blake Griffin", 30),\ + "Steve Nash": ("Steve Nash", 45),\ + "Jason Kidd": ("Jason Kidd", 45),\ + "Dirk Nowitzki": ("Dirk Nowitzki", 40),\ + "Paul George": ("Paul George", 28),\ + "Grant Hill": ("Grant Hill", 46),\ + "Shaquile O'Neal": ("Shaquile O'Neal", 47),\ + "JaVale McGee": ("JaVale McGee", 31),\ + "Dwight Howard": ("Dwight Howard", 33); + +INSERT\ + VERTEX bachelor(name, speciality)\ +VALUES\ + "Tim Duncan": ("Tim Duncan", "psychology"); + +INSERT\ + VERTEX team(name)\ +VALUES\ + "Nets": ("Nets"),\ + "Pistons": ("Pistons"),\ + "Bucks": ("Bucks"),\ + "Mavericks": ("Mavericks"),\ + "Clippers": ("Clippers"),\ + "Thunders": ("Thunders"),\ + "Lakers": ("Lakers"),\ + "Jazz": ("Jazz"),\ + "Nuggets": ("Nuggets"),\ + "Wizards": ("Wizards"),\ + "Pacers": ("Pacers"),\ + "Timberwolves": ("Timberwolves"),\ + "Hawks": ("Hawks"),\ + "Warriors": ("Warriors"),\ + "Magic": ("Magic"),\ + "Rockets": ("Rockets"),\ + "Pelicans": ("Pelicans"),\ + "Raptors": ("Raptors"),\ + "Spurs": ("Spurs"),\ + "Heat": ("Heat"),\ + "Grizzlies": ("Grizzlies"),\ + "Knicks": ("Knicks"),\ + "Suns": ("Suns"),\ + "Hornets": ("Hornets"),\ + "Cavaliers": ("Cavaliers"),\ + "Kings": ("Kings"),\ + "Celtics": ("Celtics"),\ + "76ers": ("76ers"),\ + "Trail Blazers": ("Trail Blazers"),\ + "Bulls": ("Bulls"); + +INSERT\ + EDGE serve(start_year, end_year)\ +VALUES\ + "Amar'e Stoudemire" -> "Suns": (2002, 2010),\ + "Amar'e Stoudemire" -> "Knicks": (2010, 2015),\ + "Amar'e Stoudemire" -> "Heat": (2015, 2016),\ + "Russell Westbrook" -> "Thunders": (2008, 2019),\ + "James Harden" -> "Thunders": (2009, 2012),\ + "James Harden" -> "Rockets": (2012, 2019),\ + "Kobe Bryant" -> "Lakers": (1996, 2016),\ + "Tracy McGrady" -> "Raptors": (1997, 2000),\ + "Tracy McGrady" -> "Magic": (2000, 2004),\ + "Tracy McGrady" -> "Rockets": (2004, 2010),\ + "Tracy McGrady" -> "Spurs": (2013, 2013),\ + "Chris Paul" -> "Hornets": (2005, 2011),\ + "Chris Paul" -> "Clippers": (2011, 2017),\ + "Chris Paul" -> "Rockets": (2017, 2021),\ + "Boris Diaw" -> "Hawks": (2003, 2005),\ + "Boris Diaw" -> "Suns": (2005, 2008),\ + "Boris Diaw" -> "Hornets": (2008, 2012),\ + "Boris Diaw" -> "Spurs": (2012, 2016),\ + "Boris Diaw" -> "Jazz": (2016, 2017),\ + "LeBron James" -> "Cavaliers": (2003, 2010),\ + "LeBron James" -> "Heat": (2010, 2014),\ + "LeBron James" -> "Cavaliers"@1: (2014, 2018),\ + "LeBron James" -> "Lakers": (2018, 2019),\ + "Klay Thompson" -> "Warriors": (2011, 2019),\ + "Kristaps Porzingis" -> "Knicks": (2015, 2019),\ + "Kristaps Porzingis" -> "Mavericks": (2019, 2020),\ + "Jonathon Simmons" -> "Spurs": (2015, 2017),\ + "Jonathon Simmons" -> "Magic": (2017, 2019),\ + "Jonathon Simmons" -> "76ers": (2019, 2019),\ + "Marco Belinelli" -> "Warriors": (2007, 2009),\ + "Marco Belinelli" -> "Raptors": (2009, 2010),\ + "Marco Belinelli" -> "Hornets": (2010, 2012),\ + "Marco Belinelli" -> "Bulls": (2012, 2013),\ + "Marco Belinelli" -> "Spurs": (2013, 2015),\ + "Marco Belinelli" -> "Kings": (2015, 2016),\ + "Marco Belinelli" -> "Hornets"@1: (2016, 2017),\ + "Marco Belinelli" -> "Hawks": (2017, 2018),\ + "Marco Belinelli" -> "76ers": (2018, 2018),\ + "Marco Belinelli" -> "Spurs"@1: (2018, 2019),\ + "Luka Doncic" -> "Mavericks": (2018, 2019),\ + "David West" -> "Hornets": (2003, 2011),\ + "David West" -> "Pacers": (2011, 2015),\ + "David West" -> "Spurs": (2015, 2016),\ + "David West" -> "Warriors": (2016, 2018),\ + "Tony Parker" -> "Spurs": (1999, 2018),\ + "Tony Parker" -> "Hornets": (2018, 2019),\ + "Danny Green" -> "Cavaliers": (2009, 2010),\ + "Danny Green" -> "Spurs": (2010, 2018),\ + "Danny Green" -> "Raptors": (2018, 2019),\ + "Rudy Gay" -> "Grizzlies": (2006, 2013),\ + "Rudy Gay" -> "Raptors": (2013, 2013),\ + "Rudy Gay" -> "Kings": (2013, 2017),\ + "Rudy Gay" -> "Spurs": (2017, 2019),\ + "LaMarcus Aldridge" -> "Trail Blazers": (2006, 2015),\ + "LaMarcus Aldridge" -> "Spurs": (2015, 2019),\ + "Tim Duncan" -> "Spurs": (1997, 2016),\ + "Kevin Durant" -> "Thunders": (2007, 2016),\ + "Kevin Durant" -> "Warriors": (2016, 2019),\ + "Stephen Curry" -> "Warriors": (2009, 2019),\ + "Ray Allen" -> "Bucks": (1996, 2003),\ + "Ray Allen" -> "Thunders": (2003, 2007),\ + "Ray Allen" -> "Celtics": (2007, 2012),\ + "Ray Allen" -> "Heat": (2012, 2014),\ + "Tiago Splitter" -> "Spurs": (2010, 2015),\ + "Tiago Splitter" -> "Hawks": (2015, 2017),\ + "Tiago Splitter" -> "76ers": (2017, 2017),\ + "DeAndre Jordan" -> "Clippers": (2008, 2018),\ + "DeAndre Jordan" -> "Mavericks": (2018, 2019),\ + "DeAndre Jordan" -> "Knicks": (2019, 2019),\ + "Paul Gasol" -> "Grizzlies": (2001, 2008),\ + "Paul Gasol" -> "Lakers": (2008, 2014),\ + "Paul Gasol" -> "Bulls": (2014, 2016),\ + "Paul Gasol" -> "Spurs": (2016, 2019),\ + "Paul Gasol" -> "Bucks": (2019, 2020),\ + "Aron Baynes" -> "Spurs": (2013, 2015),\ + "Aron Baynes" -> "Pistons": (2015, 2017),\ + "Aron Baynes" -> "Celtics": (2017, 2019),\ + "Cory Joseph" -> "Spurs": (2011, 2015),\ + "Cory Joseph" -> "Raptors": (2015, 2017),\ + "Cory Joseph" -> "Pacers": (2017, 2019),\ + "Vince Carter" -> "Raptors": (1998, 2004),\ + "Vince Carter" -> "Nets": (2004, 2009),\ + "Vince Carter" -> "Magic": (2009, 2010),\ + "Vince Carter" -> "Suns": (2010, 2011),\ + "Vince Carter" -> "Mavericks": (2011, 2014),\ + "Vince Carter" -> "Grizzlies": (2014, 2017),\ + "Vince Carter" -> "Kings": (2017, 2018),\ + "Vince Carter" -> "Hawks": (2018, 2019),\ + "Marc Gasol" -> "Grizzlies": (2008, 2019),\ + "Marc Gasol" -> "Raptors": (2019, 2019),\ + "Ricky Rubio" -> "Timberwolves": (2011, 2017),\ + "Ricky Rubio" -> "Jazz": (2017, 2019),\ + "Ben Simmons" -> "76ers": (2016, 2019),\ + "Giannis Antetokounmpo" -> "Bucks": (2013, 2019),\ + "Rajon Rondo" -> "Celtics": (2006, 2014),\ + "Rajon Rondo" -> "Mavericks": (2014, 2015),\ + "Rajon Rondo" -> "Kings": (2015, 2016),\ + "Rajon Rondo" -> "Bulls": (2016, 2017),\ + "Rajon Rondo" -> "Pelicans": (2017, 2018),\ + "Rajon Rondo" -> "Lakers": (2018, 2019),\ + "Manu Ginobili" -> "Spurs": (2002, 2018),\ + "Kyrie Irving" -> "Cavaliers": (2011, 2017),\ + "Kyrie Irving" -> "Celtics": (2017, 2019),\ + "Carmelo Anthony" -> "Nuggets": (2003, 2011),\ + "Carmelo Anthony" -> "Knicks": (2011, 2017),\ + "Carmelo Anthony" -> "Thunders": (2017, 2018),\ + "Carmelo Anthony" -> "Rockets": (2018, 2019),\ + "Dwyane Wade" -> "Heat": (2003, 2016),\ + "Dwyane Wade" -> "Bulls": (2016, 2017),\ + "Dwyane Wade" -> "Cavaliers": (2017, 2018),\ + "Dwyane Wade" -> "Heat"@1: (2018, 2019),\ + "Joel Embiid" -> "76ers": (2014, 2019),\ + "Damian Lillard" -> "Trail Blazers": (2012, 2019),\ + "Yao Ming" -> "Rockets": (2002, 2011),\ + "Kyle Anderson" -> "Spurs": (2014, 2018),\ + "Kyle Anderson" -> "Grizzlies": (2018, 2019),\ + "Dejounte Murray" -> "Spurs": (2016, 2019),\ + "Blake Griffin" -> "Clippers": (2009, 2018),\ + "Blake Griffin" -> "Pistons": (2018, 2019),\ + "Steve Nash" -> "Suns": (1996, 1998),\ + "Steve Nash" -> "Mavericks": (1998, 2004),\ + "Steve Nash" -> "Suns"@1: (2004, 2012),\ + "Steve Nash" -> "Lakers": (2012, 2015),\ + "Jason Kidd" -> "Mavericks": (1994, 1996),\ + "Jason Kidd" -> "Suns": (1996, 2001),\ + "Jason Kidd" -> "Nets": (2001, 2008),\ + "Jason Kidd" -> "Mavericks"@1: (2008, 2012),\ + "Jason Kidd" -> "Knicks": (2012, 2013),\ + "Dirk Nowitzki" -> "Mavericks": (1998, 2019),\ + "Paul George" -> "Pacers": (2010, 2017),\ + "Paul George" -> "Thunders": (2017, 2019),\ + "Grant Hill" -> "Pistons": (1994, 2000),\ + "Grant Hill" -> "Magic": (2000, 2007),\ + "Grant Hill" -> "Suns": (2007, 2012),\ + "Grant Hill" -> "Clippers": (2012, 2013),\ + "Shaquile O'Neal" -> "Magic": (1992, 1996),\ + "Shaquile O'Neal" -> "Lakers": (1996, 2004),\ + "Shaquile O'Neal" -> "Heat": (2004, 2008),\ + "Shaquile O'Neal" -> "Suns": (2008, 2009),\ + "Shaquile O'Neal" -> "Cavaliers": (2009, 2010),\ + "Shaquile O'Neal" -> "Celtics": (2010, 2011),\ + "JaVale McGee" -> "Wizards": (2008, 2012),\ + "JaVale McGee" -> "Nuggets": (2012, 2015),\ + "JaVale McGee" -> "Mavericks": (2015, 2016),\ + "JaVale McGee" -> "Warriors": (2016, 2018),\ + "JaVale McGee" -> "Lakers": (2018, 2019),\ + "Dwight Howard" -> "Magic": (2004, 2012),\ + "Dwight Howard" -> "Lakers": (2012, 2013),\ + "Dwight Howard" -> "Rockets": (2013, 2016),\ + "Dwight Howard" -> "Hawks": (2016, 2017),\ + "Dwight Howard" -> "Hornets": (2017, 2018),\ + "Dwight Howard" -> "Wizards": (2018, 2019); + +INSERT\ + EDGE like(likeness)\ +VALUES\ + "Amar'e Stoudemire" -> "Steve Nash": (90),\ + "Russell Westbrook" -> "Paul George": (90),\ + "Russell Westbrook" -> "James Harden": (90),\ + "James Harden" -> "Russell Westbrook": (80),\ + "Tracy McGrady" -> "Kobe Bryant": (90),\ + "Tracy McGrady" -> "Grant Hill": (90),\ + "Tracy McGrady" -> "Rudy Gay": (90),\ + "Chris Paul" -> "LeBron James": (90),\ + "Chris Paul" -> "Carmelo Anthony": (90),\ + "Chris Paul" -> "Dwyane Wade": (90),\ + "Boris Diaw" -> "Tony Parker": (80),\ + "Boris Diaw" -> "Tim Duncan": (80),\ + "LeBron James" -> "Ray Allen": (100),\ + "Klay Thompson" -> "Stephen Curry": (90),\ + "Kristaps Porzingis" -> "Luka Doncic": (90),\ + "Marco Belinelli" -> "Tony Parker": (50),\ + "Marco Belinelli" -> "Tim Duncan": (55),\ + "Marco Belinelli" -> "Danny Green": (60),\ + "Luka Doncic" -> "Dirk Nowitzki": (90),\ + "Luka Doncic" -> "Kristaps Porzingis": (90),\ + "Luka Doncic" -> "James Harden": (80),\ + "Tony Parker" -> "Tim Duncan": (95),\ + "Tony Parker" -> "Manu Ginobili": (95),\ + "Tony Parker" -> "LaMarcus Aldridge": (90),\ + "Danny Green" -> "Marco Belinelli": (83),\ + "Danny Green" -> "Tim Duncan": (70),\ + "Danny Green" -> "LeBron James": (80),\ + "Rudy Gay" -> "LaMarcus Aldridge": (70),\ + "LaMarcus Aldridge" -> "Tony Parker": (75),\ + "LaMarcus Aldridge" -> "Tim Duncan": (75),\ + "Tim Duncan" -> "Tony Parker": (95),\ + "Tim Duncan" -> "Manu Ginobili": (95),\ + "Ray Allen" -> "Rajon Rondo": (9),\ + "Tiago Splitter" -> "Tim Duncan": (80),\ + "Tiago Splitter" -> "Manu Ginobili": (90),\ + "Paul Gasol" -> "Kobe Bryant": (90),\ + "Paul Gasol" -> "Marc Gasol": (99),\ + "Aron Baynes" -> "Tim Duncan": (80),\ + "Vince Carter" -> "Tracy McGrady": (90),\ + "Vince Carter" -> "Jason Kidd": (70),\ + "Marc Gasol" -> "Paul Gasol": (99),\ + "Ben Simmons" -> "Joel Embiid": (80),\ + "Rajon Rondo" -> "Ray Allen": (-1),\ + "Manu Ginobili" -> "Tim Duncan": (90),\ + "Kyrie Irving" -> "LeBron James": (13),\ + "Carmelo Anthony" -> "LeBron James": (90),\ + "Carmelo Anthony" -> "Chris Paul": (90),\ + "Carmelo Anthony" -> "Dwyane Wade": (90),\ + "Dwyane Wade" -> "LeBron James": (90),\ + "Dwyane Wade" -> "Chris Paul": (90),\ + "Dwyane Wade" -> "Carmelo Anthony": (90),\ + "Joel Embiid" -> "Ben Simmons": (80),\ + "Damian Lillard" -> "LaMarcus Aldridge": (80),\ + "Yao Ming" -> "Tracy McGrady": (90),\ + "Yao Ming" -> "Shaquile O'Neal": (90),\ + "Dejounte Murray" -> "Tim Duncan": (99),\ + "Dejounte Murray" -> "Tony Parker": (99),\ + "Dejounte Murray" -> "Manu Ginobili": (99),\ + "Dejounte Murray" -> "Marco Belinelli": (99),\ + "Dejounte Murray" -> "Danny Green": (99),\ + "Dejounte Murray" -> "LeBron James": (99),\ + "Dejounte Murray" -> "Russell Westbrook": (99),\ + "Dejounte Murray" -> "Chris Paul": (99),\ + "Dejounte Murray" -> "Kyle Anderson": (99),\ + "Dejounte Murray" -> "Kevin Durant": (99),\ + "Dejounte Murray" -> "James Harden": (99),\ + "Dejounte Murray" -> "Tony Parker": (99),\ + "Blake Griffin" -> "Chris Paul": (-1),\ + "Steve Nash" -> "Amar'e Stoudemire": (90),\ + "Steve Nash" -> "Dirk Nowitzki": (88),\ + "Steve Nash" -> "Stephen Curry": (90),\ + "Steve Nash" -> "Jason Kidd": (85),\ + "Jason Kidd" -> "Vince Carter": (80),\ + "Jason Kidd" -> "Steve Nash": (90),\ + "Jason Kidd" -> "Dirk Nowitzki": (85),\ + "Dirk Nowitzki" -> "Steve Nash": (80),\ + "Dirk Nowitzki" -> "Jason Kidd": (80),\ + "Dirk Nowitzki" -> "Dwyane Wade": (10),\ + "Paul George" -> "Russell Westbrook": (95),\ + "Grant Hill" -> "Tracy McGrady": (90),\ + "Shaquile O'Neal" -> "JaVale McGee": (100),\ + "Shaquile O'Neal" -> "Tim Duncan": (80); + +INSERT\ + EDGE teammate(start_year, end_year)\ +VALUES\ + "Tony Parker" -> "Tim Duncan": (2001, 2016),\ + "Tony Parker" -> "Manu Ginobili": (2002, 2018),\ + "Tony Parker" -> "LaMarcus Aldridge": (2015, 2018),\ + "Tony Parker" -> "Kyle Anderson": (2014, 2016),\ + "Tim Duncan" -> "Tony Parker": (2001, 2016),\ + "Tim Duncan" -> "Manu Ginobili": (2002, 2016),\ + "Tim Duncan" -> "LaMarcus Aldridge": (2015, 2016),\ + "Tim Duncan" -> "Danny Green": (2010, 2016),\ + "Manu Ginobili" -> "Tim Duncan": (2002, 2016),\ + "Manu Ginobili" -> "Tony Parker": (2002, 2016);