How transactions guard your database, PL-SQL Programming

How Transactions Guard Your Database

The transaction is a sequence of SQL data manipulation statements which does a logical unit of work. The Oracle treats the sequence of SQL statements as a unit so that all the changes brought about by the statements are either committed (made permanent) or rolled back (undone) at similar time. If your program fails in the center of a transaction, then the database is automatically restored to its previous state.

The first SQL statements in your program begin a transaction. Whenever a transaction ends, the next SQL statement automatically begins the other transaction. And hence, every SQL statement is part of the transaction. The distributed transaction involves at least one SQL statement which updates the data at multiple nodes in a distributed database.

The COMMIT and ROLLBACK statements assures that all the database changes brought about by the SQL operations are either made permanent or undone at similar time. All the SQL statements executed as the last commit or rollback make up the present transaction. The SAVEPOINT statement names and marks the present point in the processing of a transaction.

Posted Date: 10/4/2012 4:51:02 AM | Location : United States







Related Discussions:- How transactions guard your database, Assignment Help, Ask Question on How transactions guard your database, Get Answer, Expert's Help, How transactions guard your database Discussions

Write discussion on How transactions guard your database
Your posts are moderated
Related Questions
Updating Variables For assignment, SQL uses the key word SET, as in SET X = X + 1 (read as "set X equal to X+1") rather than X: = X + 1 as found in many computer languages.

a. Write an anonymous block that contains a PL/SQL function. Given an order number orderNo, the function will calculate the total number of the parts in the order. Then the anonym

Parameter and Keyword Description: package_name: This construct identifies the package. AUTHID Clause: This determine whether all the packaged subprograms impleme

Tautologies: Above given table allows us to read the truth of the connectives in the next manner. Just expect we are looking at row three. It means this says that, if there P

Updating by insertion Syntax : INSERT INTO ENROLMENT VALUES (SID ('S4'), 'Devinder', CID ('C1'));

Example of ADD CONSTRAINT in SQL Example: Alternative formulation for MAX_ENROLMENTS ALTER TABLE IS_ENROLLED_ON ADD CONSTRAINT MAX_ENROLMENTS CHECK ((SELECT COUNT (*)

Entering and Exiting If you enter the executable part of an autonomous routine, the major transaction suspends. When you exit the routine, the major transaction resumes. To ex

Quantification in SQL To quantify something, as the theory book has it, is to state its quantity, to say how many of it there are. For example, in Tutorial D the expression CO

Existential Quantification - SQL Existential quantification-stating that something is true of at least one object under consideration-can be expressed by OR(r,c), meaning tha

Defining and Declaring Records To create records, you have to define a RECORD type, and then declare records of that type. You may also define RECORD types in the declarative