-
Notifications
You must be signed in to change notification settings - Fork 52
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
Association schema adjustment #1822
base: Development
Are you sure you want to change the base?
Conversation
- Adjust schema to remove association record whenever either internal association is deleted. Current schema sets occidAssociate field to null when linked occurrence is deleted, thus resulting in non-informative orphaned associations.
Update branch with latest developments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm a little confused. It seems like there's a mismatch between the description and the code.
The description
Adjust schema to remove association record whenever either internal association is deleted. Current schema sets occidAssociate field to null when linked occurrence is deleted, thus resulting in non-informative orphaned associations.
makes it sound like what is desired is to delete the association record if the occurrence corresponding to either occid or occidAssociate are deleted.
What I think would happen instead is that the user could no longer delete the occurrence, creating user, or editing user if the association exists, forcing the end user to have to delete the association first. Is this the desired behavior?
Yes, this PR is from prior to our last Dev meeting, where we decided that we would play it safer and restrict, but we also also realized that we needed to review the behaviors of the current controls, as well as the occurrence remapping tools. I'll switch this over to draft for now, until we reach an agreement on the best actions. However, within your dev environment, you probably want to change the FK to restrict, and delete the orphaned internal associations (null occidAssociate), which shouldn't exist nor be allowed. |
Pull Request Checklist:
Pre-Approval
master
branch and squash and merged back into themaster
branch.Development
branch, NOTmaster
Post-Approval
Development
branch, remember to use the squash & merge optionDevelopment
branch into the master branch, remember to use the merge optionmaster
branch, a subsequent PR frommaster
intoDevelopment
should be made merge option (i.e., no squash).Development
branch before a tagged release (i.e., before an imminent merge into the master branch), make sure to notify the team and lock theDevelopment
branch to prevent accidental merges while QA takes place. Follow the release protocol here.Thanks for contributing and keeping it clean!