Transactional Control in Oracle

Transactional Control in Oracle:

When we say Transactional control then the first question that comes is like “What is a Transaction?”
It’s a group of commands that can be committed and stored in the database or roll backed and undone.
Usually when we go to a database and change a couple of columns or a set of records on a table then we need to commit that change what we have done.  If we do not commit then we should roll back (means undo it).
The transaction change command that can be made one after other and they can all be committed or undone with a single group.
Normally when we do any changes on the database there will be the four parts that happens. Like we have the database, redo logs, rollback and the person who made the changes. 
So whenever the person does any changes on the transaction then data get changed before committing or rollback. The redo logs will be written to storing record change is made and also the rollback is written too but a little different on what redo logs writes, so when the person commits then the only thing that we do is only to delete the rollback because the changes are already been made to the redo logs and the database.
When we rollback before commit command executed, it will be applied that changes are been made to the redo logs but this also get recorded that the undo changes made by rollback command then rollback command is deleted.
A small note on what I have mentioned above :
When the data get changed before COMMIT or ROLLBACK command:
  • Database is changed.
  • Logs are written.
  • Rollback is written.
  • Rollback is deleted.
  • Rollback is applied to the database.
  • Rollback is recorded in redo logs.
  • Rollback is deleted.
The above note is the basic of a transaction or a database change works in Oracle.
The most important part is the first thing that gets change is the redo logs because it contains records of both changes and rollback undo.

One thought on “Transactional Control in Oracle

  1. Pingback: Transactional Control in Oracle | Sloba's Blog

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.