A transaction in databases usually means a sequence of information exchange and related work (such as row updates or inserts) that is treated as a unit for the purposes of satisfying a specific request and for ensuring database integrity. All tasks in a transaction either pass or fail, making it necessary for critical functions.