Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: using system event triggers

Re: using system event triggers

From: Juan Cachito Reyes Pacheco <jreyes_at_dazasoftware.com>
Date: Fri, 27 Feb 2004 09:30:58 -0400
Message-ID: <006701c3fd35$f69e2840$2501a8c0@dazasoftware.com>


Imagine, mistakely you do bad the trigger, or the condition changes for some reason, and you can start your database neither to change the trigger, this really really will be not funny. killing your database based on a bug, could create future block problems.

I agree with Thomas, find another way
Restricting access (there are several way to do this), you coud do a logon trigger, if the condition you want don't work there is no logons, except as sysdba.

Other idea in windows you could for example if there is a condition true, schedule a task through java to shutdown the database in 30 seconds using at command line. This is more near to what you want and less dangeros to your database.

  Josh,

  This is a very bad idea. Even if you *could* do it, how in the world would you be able to fix it? If you cant start the database, then it's basically hosed.

  Just what are you trying to accomplish?

  Tom Mercadante
  Oracle Certified Professional

    -----Original Message-----
    From: Josh Collier [mailto:Josh.Collier_at_Banfield.net]     Sent: Thursday, February 26, 2004 7:42 PM     To: 'oracle-l_at_freelists.org'
    Subject: using system event triggers

    Is there a way to use a system event trigger to prevent completion of database open if a criteria isn't met

    some psuedo code to elaborate:

    CREATE OR REPLACE TRIGGER sys.post_dup_check

    AFTER     STARTUP     ON DATABASE     DECLARE     db_name VARCHAR2 (50);

    BEGIN     db_name := ora_database_name;

    IF db_name ! = ' whatever .WORLD'

    then don't open

    END IF;     END;     /



Please see the official ORACLE-L FAQ: http://www.orafaq.com

To unsubscribe send email to: oracle-l-request_at_freelists.org put 'unsubscribe' in the subject line.
--

Archives are at http://www.freelists.org/archives/oracle-l/ FAQ is at http://www.freelists.org/help/fom-serve/cache/1.html
Received on Fri Feb 27 2004 - 07:31:18 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US