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
Parameter & Keyword Description: function_name: The user-defined function is identifying by that keyword. parameter_name: This identifies the formal parameter that

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

IN OUT Mode An IN OUT parameter passes initial values to the subprogram being called and return efficient values to the caller. Within the subprogram, an IN OUT parameter acts

Datatype Conversion At times it is necessary to convert a value from one datatype to another. For e.g. if you want to inspect a rowid, you should convert it to a character stri

Inserting Objects: You can use the INSERT statement to add objects to an object table. In the illustration below, you insert a Person object into the object table persons:

Why Use Cursor Variables ? Primarily, you use the cursor variables to pass the query result sets between the PL/SQL stored subprograms and different clients. Neither PL/SQL nor

COMMIT Statement The COMMIT statement explicitly makes everlasting changes to the database during the present transaction. The Changes made to the database are not considered e

Enrolment was split - SQL Example shows how relvars IS_CALLED and IS_ENROLLED_ON can be derived from the original ENROLMENT relvar, using projection in the initial assignment

Implicit Cursors The Oracle implicitly opens a cursor to process each SQL statement not related with an explicitly declared cursor. The PL/SQL lets you refer to the most recen

OUT Mode An OUT parameter returns values to the caller of a subprogram. Within the subprogram, an OUT parameter act like a variable. That means that you can use an OUT formal