Closed EyalSi closed 5 years ago
@EyalSi did you confirm this as a bug? Have you tried asking in another forum? If you found a solution, link us up with your answer or, if someone confirmed this as a bug we can mark it as such.
Sails v0.10 is finally here: Upgrade | Contribution Guide | Stackoverflow | Google Group | IRC | Build Status
Is this a bug? @uncletammy @loicsaintroch
@EyalSi, it looks like you're attempting a Many-To-Many association but you forgot the via
key in your model configurations. You'll also need the dominate
key set on at least one of the models so Waterline knows how to build the join table.
See Many-To-Many Association Docs for more info
For future reference, you're likely to get a quicker response if you post the version of Sails and Waterline you are using as well as the adapter name and version.
The answer is above and can be found in search results. I'm going to close this up. Thanks all~
I'm trying the following code to populate the database. Seems like on the third level of data (categories2), I'm getting the below error.
Any idea how can I import the data to the db - recursively? Is it a bug?
This is the error I'm getting: Error (E_UNKNOWN) :: Encountered an unexpected error Details: [ { type: 'insert', collection: 'item', values: { name: 'Vegi Salad 2', price: 53, selections: [Object], createdAt: Mon Jun 09 2014 13:01:05 GMT+0000 (UTC), updatedAt: Mon Jun 09 2014 13:01:05 GMT+0000 (UTC) }, err: undefined } ]