-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
photo.views/isPublished are required fields #6970
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
In the many-to-many photos/albums example - photo.views is required field
Fixes `null value in column "isPublished" violates not-null constraint`
|
Where's that model defined? I can't find it in the README. |
|
The Photo model is the original class created in the tutorial https://github.com/typeorm/typeorm/blob/master/README.md#adding-table-columns I'm using postgres, and typeorm created a Sorry if I've misread the tutorial and done something wrong to get to this point. |
|
I guess the other solution is to originally introduce nullable earlier in the tutorial for these two fields? |
|
Change looks correct. Thank you! |
* photo.views is required field In the many-to-many photos/albums example - photo.views is required field * photo.isPublished must be provided Fixes `null value in column "isPublished" violates not-null constraint`
* photo.views is required field In the many-to-many photos/albums example - photo.views is required field * photo.isPublished must be provided Fixes `null value in column "isPublished" violates not-null constraint`
In the many-to-many photos/albums example - photo.views is required field
I was following through the tutorial using postgres, and my
viewscolumn is defined as:Later, I was required to provide
photo.views = 1for the photo/albums example