Ending transactions, PL-SQL Programming

Assignment Help:

Ending Transactions

A good quality programming practice is to commit or roll back every transaction explicitly. Whether you rollback or issue the commit in your PL/SQL program or in the host atmosphere, it depends on the flow of application logic. When you neglect to commit or roll back a transaction explicitly, the host atmosphere determines its last state.

For illustration, in the SQL Plus atmosphere, if your PL/SQL block does not involve a COMMIT or ROLLBACK statement, the final state of your transaction totally depends on what you do after running the block. When you execute the data control, data definition, or COMMIT statement or if you issue the DISCONNECT, EXIT, or QUIT command, the Oracle commits the transaction. When you execute a ROLLBACK statement or abandon the SQL Plus session, the Oracle rolls back the transaction.

In the Oracle Pre-compiler atmosphere, if your program does not expire in general, the Oracle rolls back your transaction. The program terminates generally if it explicitly commits or rolls back work and disconnects from the Oracle using the RELEASE parameter, which is as shown:

EXEC SQL COMMIT WORK RELEASE;


Related Discussions:- Ending transactions

Blocks, Blocks: The fundamental program unit in the PL/SQL is the bloc...

Blocks: The fundamental program unit in the PL/SQL is the block. The PL/SQL block is defined by the keywords BEGIN, DECLARE, EXCEPTION, and END. These keywords partition the b

Goto statement - sequential control, GOTO Statement The GOTO statement b...

GOTO Statement The GOTO statement branches to a label unconditionally. The label must be exclusive within its scope and should precede an executable statement or a PL/SQL block.

Package - pl/sql programming, What Is a Package? The package is a sch...

What Is a Package? The package is a schema object that group logically related PL/SQL items, types, and subprograms. The Packages usually have 2 parts, a specification & a bo

Example of when or then constraints - sql, Example of WHEN or THEN Constrai...

Example of WHEN or THEN Constraints A concrete example showing how SQL supports WHEN/THEN constraints CREATE TABLE SAL_HISTORY (EmpNo CHAR (6), Salary INTEGER NOT NULL,

Seeking a programmer to design a legal document, Seeking a programmer to de...

Seeking a programmer to design a legal document with pre-existing fields that could allow the auto-population of client(s) information (i.e. Name, Account Number, Address etc.) int

Relational operators-comparison operators, Relational Operators The rela...

Relational Operators The relational operators permit you to compare randomly complex expressions. The list below provides the meaning of each operator:

Null statement-sequential control, NULL Statement The NULL statement c...

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

Iteration schemes- iterative control, Iteration Schemes The bounds of a ...

Iteration Schemes The bounds of a loop range can be variables, literals, variables, or expressions but must compute to integers. Below are some of the examples. As you can see t

In mode - parameter modes, IN Mode An IN parameter pass the values to ...

IN Mode An IN parameter pass the values to the subprogram being called. Within the subprogram, an IN parameter acts like a constant. And hence, it cannot be assigned a value.

Boolean values-assignments in pl/sql, Boolean Values Only the values TRU...

Boolean Values Only the values TRUE, FALSE, & NULL can be assigned to a Boolean variable. For illustration, given the declaration DECLARE done BOOLEAN; the following statements

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd