0

If trigger is BEFORE I guess trigger will run before the check constraint.

But what is the order if trigger is AFTER? Does the check run first?

1
  • 3
    before triggers -> non-deffered constraints -> after triggers (if constraints passed) Commented Jul 6, 2021 at 16:15

1 Answer 1

2

Don't guess, know Create Trigger:

The trigger can be specified to fire before the operation is attempted on a row (before constraints are checked and the INSERT, UPDATE, or DELETE is attempted); or after the operation has completed (after constraints are checked and the INSERT, UPDATE, or DELETE has completed); ...

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.