Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
ACID
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Consistency failure === Consistency is a very general term, which demands that the data must meet all validation rules. In the previous example, the validation is a requirement that {{math|{{var|A}} + {{var|B}} {{=}} 100}}. All validation rules must be checked to ensure consistency. Assume that a transaction attempts to subtract 10 from {{var|A}} without altering {{var|B}}. Because consistency is checked after each transaction, it is known that {{math|{{var|A}} + {{var|B}} {{=}} 100}} before the transaction begins. If the transaction removes 10 from {{var|A}} successfully, atomicity will be achieved. However, a validation check will show that {{math|{{var|A}} + {{var|B}} {{=}} 90}}, which is inconsistent with the rules of the database. The entire transaction must be canceled and the affected rows rolled back to their pre-transaction state. If there had been other constraints, triggers, or cascades, every single change operation would have been checked in the same way as above before the transaction was committed. Similar issues may arise with other constraints. We may have required the data types of both {{var|A}} and {{var|B}} to be integers. If we were then to enter, say, the value 13.5 for {{var|A}}, the transaction will be canceled, or the system may give rise to an alert in the form of a trigger (if/when the trigger has been written to this effect). Another example would be integrity constraints, which would not allow us to delete a row in one table whose primary key is referred to by at least one [[foreign key]] in other tables.
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
ACID
(section)
Add topic