Vinelab / NeoEloquent

The Neo4j OGM for Laravel
MIT License
633 stars 197 forks source link

No relationship start node specified #282

Closed fzhan closed 6 years ago

fzhan commented 6 years ago
  1. laravel 5.5.*
  2. neoeloquent ^1.4

$brand = new Brand ([...]); $brand->save(); // ok $series = new Series ([...]); $brand->series()->save($series);

No relationship start node specified {"exception":"[object] (Everyman\Neo4j\Exception(code: 0): No relationship start node specified at vendor/heydavid713/neo4jphp/lib/Everyman/Neo4j/Command/CreateRelationship.php:77

KonradMil commented 6 years ago

Have you tried approach like: $series = new Series ([...]); $series->save(); $brans->series()->attach($series);

We have been using this package quite extensively and we encountered several occasion that simple switching approach was enough to fix issue.

fzhan commented 6 years ago

@KonradMil will give it a go, thanks!