Show Warnings in Oracle SQL Developer

stummj
stummj used Ask the Experts™
on
I have a trigger which SQL Developer is saying run "with warning" when I run it.
How do I see the warning?

Warning: execution completed with warning
TRIGGER company_name_to_uppercase Compiled.

This is the code which I want to simply convert the company name to uppercase irrespective of the case entered...

CREATE OR REPLACE TRIGGER company_name_to_uppercase BEFORE INSERT ON customer FOR EACH ROW
  BEGIN
    :new.company_name = UPPER(:new.company_name);
  END;
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Guy Hengel [angelIII / a3]Billing Engineer
Most Valuable Expert 2014
Top Expert 2009

Commented:
CREATE OR REPLACE TRIGGER company_name_to_uppercase BEFORE INSERT ON customer FOR EACH ROW
  BEGIN
    :new.company_name := UPPER(:new.company_name);
  END;

Author

Commented:
Thats great Angelll thank you. But how do I show warnings in SQL Developer?
Guy Hengel [angelIII / a3]Billing Engineer
Most Valuable Expert 2014
Top Expert 2009

Commented:
go to the procedures folder, and open the trigger (in the triggers folder) in edit mode. you will get the error(s) shown clearly
Success in ‘20 With a Profitable Pricing Strategy

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Author

Commented:
There isnt a triggers folder in the procedures folder... and the trigger isnt shown in the triggers folder under the top level database I presume because of the warning....

Just to be clear - your code works, thanks. WHen I ran it it appears in the triggers folder as I expected it to. So I re-produced the error condition with a new trigger (test).
Billing Engineer
Most Valuable Expert 2014
Top Expert 2009
Commented:
sorry, I should have written the triggers folder, nothing to do with the procedures folder...
once you create the trigger, you have to refresh that folder to make the new trigger appear.
if the message was "trigger created with warnings", the trigger has been created.

finally, the trigger folder will only show the triggers of the current account, and not those for other accounts.

Author

Commented:
Oh yeh - you just do a refresh, then compile and there is the problem loud and clear. Easy when you know how!!

Author

Commented:
Thanks very much. And your code works perfectly!

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial