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
Attributes: Just similar to variable, an attribute is declared with a name and datatype. The name should be exclusive within the object type. The datatype can be any Oracle ty

Selecting Objects: Suppose that you have run the SQL*Plus script below that creates object type Person and object table persons, and that you have settled the table: CREATE

Fetching with a Cursor The FETCH statements retrieve the rows in the result set one at a time. After each and every fetch, the cursor advance to the next row in the result set

MILLER-UREY' S EXPERIMENTAL PROCEDURES - They recreated the probable conditions on the primitive earth in the laboratory. An atmosphere containing hydrogen, ammonia, me

Using DEFAULT You can use the keyword DEFAULT rather than that of the assignment operator to initialize the variables. For e.g. the declaration blood_type CHAR := ’O’; it can b

Many of the reports generated from the system calculate the total dollars in purchases for a shopper. Complete the following steps to create a function named TOT_PURCH_SF that acce

NULL Statement The NULL statement clearly specifies in action; it does nothing other than to pass control to the next statement. It can, though, improve the readability. In a

Question: a) Given the following relation: Location(loc_id, bldg_code, room, capacity) The underlined field is a primary key. (i) Write a PL/SQL program using the impl

Using RENAME in combination with JOIN - SQL Example gives pairs of ids of students having the same name, by joining two renamings of IS_CALLED. Example gives an equivalent ex

CHECK Constraints in SQL A CHECK constraint is a table constraint defined using the key word CHECK, as already illustrated in several examples in this chapter. In particular,