Yes, try this one :O)
CREATE OR REPLACE TRIGGER block_toad_from_prod AFTER LOGON ON DATABASE DECLARE v_prog sys.v_$session.program%TYPE; BEGIN SELECT program INTO v_prog FROM sys.v_$session WHERE audsid = USERENV('SESSIONID') AND audsid != 0 -- Don't Check SYS Connections AND rownum = 1; -- Parallel processes will have the same AUDSID's IF UPPER(v_prog) LIKE '%TOAD%' OR UPPER(v_prog) LIKE '%T.O.A.D%' THEN RAISE_APPLICATION_ERROR(-20000, 'Toad users not allowed on PROD DB!'); END IF; END; /
Cheers, Dimitre Radoulov
My developers (who currently just use SQL Plus) now are wanting to use Quest TOAD. From what I've used it in the past, it is far too powerful for developers. (I don't trust my developers with creating tablespaces, etc.). Plus, I've found that TOAD is far too easy to delete objects, etc.
Any recommendations, etc would greatly be appreciated!
Express yourself instantly with MSN Messenger! Download today - it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/