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
Questions around cascades and soft deletes #6139
Comments
For questions, please check out the community slack or check TypeORM's documentation page on other support avenues - cheers! |
Sorry @imnotjames, I have to disagree in this case. Documentation is very incomplete when it comes to cascades and what does what. Github issues is the #1 go-to knowledge base for everything that's not documented, while community slack is all about individual issues and hard to use if you search for information. Neither here, nor in the documentation, nor on discord was I able to find useful information on what the newer cascade types actually do. Guess I'm on my own here. Will try to pull to documentation if I find out how it is supposed to work. |
Yeah, I thought these were broad enough questions to be included in the documentation rather than answered in slack. It doesn't make sense for everyone wanting to know how cascades work with typeorm to separately post in a slack channel. |
Agreed @maclockard . I'm right now making notes on what does what but it is not easy to grasp how all these settings work together. I'll possibly post info/questions here to discuss what is correct. |
GitHub issues are for reporting issues, not asking questions. It's not kept up to date and does not lead well to workflows. The issues are not stack overflow QAs. We removed the |
I don't care if you answer the question here. I agree github issues are a poor knowledge repository. I am making a request the documentation be brought up to date. It's very confusing to include two different features that share a name (cascasde) but (might?) function differently. A simple sentence explaining the difference or saying I could experimentally verify the behavior, but then I wouldn't know if the current behavior is intended or a bug, nor would a non-maintainer answering a question over slack. It's important to specify how a feature is supposed to work somewhere, and I thought in documentation would make sense. My guess of how those features differ
But not 100% confident that the above is true and not confident that any of the above behavior isn't unintended. |
I understand that now, but my initial reading of the issue did not make it seem as such. The initial reading was that this was a request for clarification beyond what reasonably can be documented. If you'd like to open a new issue explicitly requesting the documentation be improved and how I'm happy to have that in the backlog. |
I agree on issues being a bad place to search for knowledge - though typeOrm is a complex beast and looking for answers to my problems, searching the issues has often been more successful than checking the official documentation. I'm currently gathering all knowledge on cascade system(s) that I have and can find and will open a new issue/PR then. Though I think I'll need a bit of help to completely document the behavior. |
Issue type:
[x] question
[ ] bug report
[ ] feature request
[x] documentation issue
Database system/driver:
[ ]
cordova
[ ]
mongodb
[ ]
mssql
[ ]
mysql
/mariadb
[ ]
oracle
[x]
postgres
[ ]
cockroachdb
[ ]
sqlite
[ ]
sqljs
[ ]
react-native
[ ]
expo
TypeORM version:
[x]
latest
[ ]
@next
[ ]
0.x.x
(or put your version here)Question
I have a couple questions around relation cascades that are not answered by the documentation.
cascade: "remove"
and settingonDelete: "CASCADE"
?onDelete: "CASCADE"
cause soft deletes to cascade as well? or can that only be specified using thecascade
option.cascade: "recover"
mean that recovering a soft deleted object will cascade the recovery?The text was updated successfully, but these errors were encountered: