Controlling autonomous transactions, PL-SQL Programming

Controlling Autonomous Transactions

The first SQL statement in an autonomous routine starts a transaction. Whenever one transaction ends, the next SQL statement starts the other transaction. All the SQL statements executed as the last commit or rollback make up the present transaction. To control the autonomous transactions, use the statements shown below, that apply only to the present (active) transaction:

(i)COMMIT

(ii)ROLLBACK [TO savepoint_name]

(iii)SAVEPOINT savepoint_name

(iv)SET TRANSACTION

The COMMIT ends the present transaction and makes the permanent changes made during that transaction. The ROLLBACK ends the present transactions and undoes the changes made during that transaction. The ROLLBACK TO undo part of a transaction. The SAVEPOINT names and marks the present point in a transaction. The SET TRANSACTION sets the transaction properties like read/write access and isolation level.

Posted Date: 10/5/2012 4:49:31 AM | Location : United States







Related Discussions:- Controlling autonomous transactions, Assignment Help, Ask Question on Controlling autonomous transactions, Get Answer, Expert's Help, Controlling autonomous transactions Discussions

Write discussion on Controlling autonomous transactions
Your posts are moderated
Related Questions
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

What Is a Record  ? A record is a group of related data items that stored in the fields, each with its own name and datatype. Assume that you have different data about an em

Special cases of projection This section describes the identity projection, r {ALL BUT}, and the projection on no attributes, r { }, which yields TABLE_DUM when r is empty, ot

Records Records are the items of the type RECORD. The Records have exclusively named fields that can store the data values of various types. And hence, a record treat associate

1- You can check attribute names from each table in DBF11 by running for example:  desc dbf11.Member;  desc dbf11.Agent;  desc dbf11.Producer; Because some attribute names in

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.

Question 1 . Compare SQL and PL/SQL Question 2 . Write a database trigger to implement the following check condition                          Given the following table

Using Cursor Attributes: Every cursor has 4 attributes: %NOTFOUND, %FOUND, %ISOPEN, and %ROWCOUNT. If appended to the cursor name, they return the helpful information about

Using a join on 2 tables, select all columns and 10 rows from the 2 tables without the use of a Cartesian product. Query: SELECT * FROM EMPLOYEE1 E JOIN STAFF S ON E.EMP_

Control Structures The Control structures are the most important PL/SQL extension to the SQL. Not only does PL/SQL let you manipulate Oracle data, it lets you process the data