Enable Tracing For A Particular Program - Page 2
DBAsupport.com Forums - Powered by vBulletin
Page 2 of 2 FirstFirst 12
Results 11 to 13 of 13

Thread: Enable Tracing For A Particular Program

  1. #11
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439

    Re: ENABLE SQL TRACING FOR A PARTICULAR SESSION

    Originally posted by Chuck
    Only comments from serious people.
    Ok, so you want us to be serious. So you first tell us how this piece of your code could be compiled:
    Code:
    ...
    if (v_program = 'EXCEL.EXE') then
    -- blah blah
    END IF; 
    else 
    null;
    ...
    ?????? What's that else part there for? Shouldn't be inside IF_ENDIF part? So much about your seriousnes...

    And then moving on... You have a select statement with a predicate "... program='EXCEL.EXE'". So what do you think which values will ever be in your variable v_program? Will it ever contain anything else than 'EXCEL.EXE'? No, it won't. So why on earth is there IF statement that check for a condition "if (v_program = 'EXCEL.EXE') then... "??? It will allways be true!

    And then most crutial thing in your trigger. You perform SELECT INTO statement without handling NO_DATA_FOUND exception! You are lucky your trigger didn't get compiled at all, because if it were, noone will be able to connect to your database if his/here program weren't called 'EXCEL.EXE'!

    If you realy created the trigger with the code you presented here, then it's obvious that it is in INVALID state and is not firing at all. So it's not the trigger that is causing tracing of all session, it must be your system settings that are doing it.

    So I think its time for you to get serious...
    Last edited by jmodic; 03-16-2004 at 02:00 AM.
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

  2. #12
    Join Date
    Jun 2000
    Location
    Madrid, Spain
    Posts
    7,447
    I dont think exec blah works neither!

  3. #13
    Join Date
    Jun 2001
    Location
    Helsinki. Finland
    Posts
    3,938
    That is one of the most interesting threads that I have ever read in this group :-)

    I liked the statement:
    "The logon trigger which I posted earlier has been compiled succesfully."

    Congratulations Chuck! Did you use "COMPILE TRIGGER xxx FORCE COMPILE;"?
    Oracle Certified Master
    Oracle Certified Professional 6i,8i,9i,10g,11g
    email: ocp_9i@yahoo.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width