Create an account

Very important

  • To access the important data of the forums, you must be active in each forum and especially in the leaks and database leaks section, send data and after sending the data and activity, data and important content will be opened and visible for you.
  • You will only see chat messages from people who are at or below your level.
  • More than 500,000 database leaks and millions of account leaks are waiting for you, so access and view with more activity.
  • Many important data are inactive and inaccessible for you, so open them with activity. (This will be done automatically)


Thread Rating:
  • 162 Vote(s) - 3.49 Average
  • 1
  • 2
  • 3
  • 4
  • 5
NOT DEFERRABLE versus DEFERRABLE INITIALLY IMMEDIATE

#1
I read this about the SQL keyword `DEFERRABLE` in *Database Systems - The Complete Book*.

> The latter *[NOT DEFERRABLE]* is default, and means that every time a database modification statement is executed, the constraint is checked immediately afterwards, if the modification could violate the foreign-key constraint.
>
> However, if we declare a constraint to be **DEFERRABLE**, then we have the option of having it wait until a transaction is complete before checking the constraint.
>
> We follow the keyword **DEFERRABLE** by either **INITIALLY DEFERRED** or **INITIALLY IMMEDIATE**. In the former case, checking will be deferred to just before each transaction commits. In the latter case, the check will be made immediately after each statement.

How is `NOT DEFERRABLE` different from `DEFERRABLE INITIALLY IMMEDIATE`? In both cases, it seems, any constraints are checked after each individual statement.
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

©0Day  2016 - 2023 | All Rights Reserved.  Made with    for the community. Connected through