Skip to content
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

Add test for SAVEPOINT with Foreign Key function #56562

Closed
Tracked by #55861
YangKeao opened this issue Oct 11, 2024 · 0 comments · Fixed by #56567
Closed
Tracked by #55861

Add test for SAVEPOINT with Foreign Key function #56562

YangKeao opened this issue Oct 11, 2024 · 0 comments · Fixed by #56567
Labels
sig/sql-infra SIG: SQL Infra type/enhancement The issue or PR belongs to an enhancement.

Comments

@YangKeao
Copy link
Member

Enhancement

We need to test the following cases:

  1. Begin-> Savepoint -> Insert parent record -> Insert child record to reference the parent record -> Rollback -> We cannot insert the child record.
  2. Begin -> Insert parent record -> Savepoint -> Insert child record -> Rollback -> We can remove the parent record now in this transaction.
  3. Insert parent record -> Begin -> Savepoint -> Insert child record -> Rollback to Savepoint. We cannot update/remove the parent record in another transaction, because the lock will be released after commit.
@YangKeao YangKeao added type/enhancement The issue or PR belongs to an enhancement. sig/sql-infra SIG: SQL Infra labels Oct 11, 2024
@ti-chi-bot ti-chi-bot bot closed this as completed in 6af2863 Oct 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sig/sql-infra SIG: SQL Infra type/enhancement The issue or PR belongs to an enhancement.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant