You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I set custom key to a model, and make a hasMany relationship, the underlying table is incorrect. tried with version (excerpt from package.json -> "orm": "~2.1.10")
Two observations which I noticed is, that it reverses the datatype, and only one is primary key, both should be primary keys... no matter what datatype.
The text was updated successfully, but these errors were encountered:
As for primary keys - the single primary key was indeed a bug. By default ORM never created keys for join tables. Whilst this is somewhat unexpected behaviour, changing it might break things for people.
To get a composite primary key, you can define the association like so:
When I set custom key to a model, and make a hasMany relationship, the underlying table is incorrect. tried with version (excerpt from package.json -> "orm": "~2.1.10")
I get these DDL commands for base tables
and many to many table
Two observations which I noticed is, that it reverses the datatype, and only one is primary key, both should be primary keys... no matter what datatype.
The text was updated successfully, but these errors were encountered: