Merged
Conversation
Collaborator
|
LGTM! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📝 요약(Summary)
users하드 삭제 시 연관 데이터가 함께 삭제되도록 FK 제약 조건을 수정했습니다.작업 이유
users는 soft delete 후 14일 뒤 hard deleteusers레코드만 삭제하더라도 연관 데이터가 FK cascade로 함께 정리되어야 함ON DELETE CASCADE가 없어 users 삭제가 막히거나, 연쇄 삭제가 중간에 끊길 수 있었음users -> answer_entries -> daily_reports삭제 체인이 완성되지 않아 정합성 문제가 발생할 수 있었음작업 내용
answer_entries.user_idFK,daily_reports.answer_entry_idFK,weekly_reports.user_idFK,monthly_reports.user_idFK,user_daily_questions.user_idFK에ON DELETE CASCADE를 적용🔗 Related Issue
💬 공유사항
✅ PR Checklist
PR이 다음 요구 사항을 충족하는지 확인하세요.