GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

GeekInterview.com  >  Interview Questions  >  Oracle  >  PL/SQL
Go To First  |  Previous Question  |  Next Question 
 PL/SQL  |  Question 233 of 237    Print  
TCL Statements in Trigger
Why are we not supposed to include TCL statements in a trigger?


  
Total Answers and Comments: 1 Last Update: September 07, 2008     Asked by: bmsrao 
  
 Sponsored Links

 
 Best Rated Answer
Submitted by: srinivas_oracle
 
Directly we cannot give TCL commands in triggers. But by using pragma autonomous_transaction we can give TCL commands in triggers.
hope this answer satisfies you.

Above answer was rated as good by the following members:
bmsrao
September 07, 2008 11:49:49   #1  
srinivas_oracle Member Since: September 2008   Contribution: 1    

RE: TCL Statements in Trigger
Directly we cannot give TCL commands in triggers. But by using pragma autonomous_transaction we can give TCL commands in triggers.
hope this answer satisfies you.

 
Is this answer useful? Yes | NoAnswer is useful 1   Answer is not useful 0Overall Rating: +1    

 Related Questions

 A set of related declarations and procedural statements is called block. 
Latest Answer : Component of PL/SQL Block are Declare(Optional), Begin(Mandatory), Exception(Optional), END(Mandatory). ...

 DECLARE  CURSOR  cursor  name,  OPEN  cursor  name,  FETCH cursor name INTO  or Record types, CLOSE cursor name. 
Latest Answer : There are two ways of processing a cursor output. These mainly depend on the type of cursor used. Cursors can be1) Static      : Declared in declarations section with a definate command2) Dynamic : Usually passed a string, which ...

 Database  trigger  is stored PL/SQL program unit associated with a specific database   table.   Usages   are  Audit  data  modifications,  
Latest Answer : A database trigger is a named pl/sql block associated with a table and fires automatically when an event occurs or something happens. Data auditing , Implementing complex business rules, security are main uses of database triggers. ...

                Insert         Update          
Latest Answer : A trigger may be a 1. DML Trigger on tables2. Instead of triggers on views3. System triggers on database or schemaBased on the way it executes statements  triggers are of two types1. Statement leve trigger2.  Row level triggerA trigger fires ...

Is it possible to use Transaction control Statements such a ROLLBACK or COMMIT in Database Trigger ? Why ?
 It  is  not  possible.  As  triggers are defined for each table, if you use COMMIT   of    ROLLBACK  in  a  trigger,  it  

 The table columns are referred as OLD.column_name and NEW.column_name.For triggers related to INSERT only NEW.column_name values only available.For  triggers related to UPDATE only OLD.column_name 
Latest Answer : OLD and NEW are two virtual tables available during database trigger execution.UPDATE statement has access to  both old and new values.INSERT  statement has access only to new values. Old values are NULL for insert statement.DELETE ...

What happens if a procedure that updates a column of table X is called in a database trigger of the same table ?
 Mutation of table occurs. 

 Raise_application_error  is  a  procedure  of  package  DBMS_STANDARD which allows  to  issue an user_defined error messages from stored sub-program or database 
Latest Answer : You can use this procedure to issue user-defined error messages from stored subprograms.You can report errors to your application and avoid returning unhandled exceptions.Syntax: raise_application_error (error_number,message[, {TRUE | FALSE}]); ...

 A  stored  procedure  is  a  sequence  of  statements that perform specific function. 
Latest Answer : A procedure is a named PL/SQL block that can accept parameters (sometimes referred to as arguments), and be invoked. Generally speaking, you use a procedure to perform an action. A procedure has a header, a declaration section, an executable section, ...

       PROCEDURE name (parameter list.....)     is     local variable declarations      BEGIN      
Latest Answer : [CREATE [OR REPLACE]] PROCEDURE procedure_name[(Optional Parameters)] {IS | AS} [PRAGMA AUTONOMOUS_TRANSACTION;] [local declarations] BEGIN executable statements [EXCEPTION exception handlers] END [name]; ...


 Sponsored Links

 
Related Articles

Querying Data with Oracle XQuery

Querying Data with Oracle XQuery Starting with Oracle Database 10g Release 2 you can take advantage of a full featured native XQuery engine integrated with the database With Oracle XQuery you can accomplish various tasks involved in developing PHP Oracle XML applications operating on any kind of dat
 

Using Oracle XML DB Repository

Using Oracle XML DB Repository Another variation on accessing and manipulating XML content stored in Oracle database is provided by Oracle XML DB repository which is an essential component of Oracle XML DB mosgoogle NOTE Oracle XML DB repository also known as XML repository is a hierarchically organ
 

Using Oracle Database for Storing, Modifying, and Retrieving XML Data

Using Oracle Database for Storing Modifying and Retrieving XML Data With Oracle XML DB you have various XML storage and XML processing options allowing you to achieve the required level of performance and scalability One of the most interesting things about Oracle XML DB is that it allows you to per
 

XML Processing in PHP and Oracle Applications

Processing XML in PHP Oracle Applications As mentioned there are two alternatives when it comes to performing XML processing in your PHP Oracle application You can perform any required XML processing using either PHP s XML extensions or PEAR XML packages or Oracle s XML features mosgoogle In the fol
 

PHP Oracle Web Development

PHP Oracle Web Development Data processing Security Caching XML Web Services and Ajax The book is written by Yuli Vaseliev a well known author of different web development and programming books PHP Oracle Web Development Data processing Security Caching XML Web Services and Ajax is a good starting b
 

Getting Started with Oracle and ODP.NET

ODP NET Developer’ s Guide by Jagadish Chatarji Pulakhandam Sunitha Paruchuri A practical guide for developers working with the Oracle Data Provider for NET and the Oracle Developer Tools for Visual Studio 2005 Application development with ODP NET Dealing with XML DB using ODP NET Oracle
 

PHP Oracle Web Development Review

PHP Oracle Web Development Data processing Security Caching XML Web Services and Ajax The book is written by Yuli Vaseliev a well known author of different web development and programming books The author is also an expert in open source technologies and SOA Service Oriented Architecture But besides
 

Step by Step Oracle PL-SQL Tutorial

This introductory tutorial to PL SQL will help you to understand the basic concepts of PL SQL Please review the following tutorials and practice the sample SQL Statements on your local Oracle Database Please note that you must learn these basic things before we actually start getting in to Advanced
 

C++ Decision Making Statements

C Decision Making Statements In this C tutorial you will learn about decision making statements if statement if… else statement switch statement conditional operator along with syntax and examples mosgoogle center Decision making is an important concept in any programming language and to
 

Working with XML in Oracle

Working with XML in Oracle Introduction to XML Extensive markup language is the language which presents data in a human readable form of text The data can be anything from a purchase order or a stock quote or weather radar or a flight schedule it can be represented using XML XML is very similar to H
 





About Us  |   Privacy Policy  |   Terms and Conditions  |   Contact  |   Site Map  |   Add Question  |   Propose Category  |   RSS Feeds  |   Articles Sitemap  |   Site Updates  |   Add Resource

Copyright © 2005 - 2008 GeekInterview.com. All Rights Reserved
Page copy protected against web site content infringement by Copyscape