Skip to Main Content

SQL Developer

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

triggers don't show messages

ziutekJan 1 2018 — edited Jan 23 2018

have two triggers, but they don't work properly. They don't show messages. when i try to insert into jobs table, rest of the code work fine.

When I insert something messages don't show, but when I use dbms_output.put_line command to show something it shows missing messages and message that it suppose to show. It's like messages from triggers wait until some new message appears.

create or replace trigger custom

  before insert on jobs

  for each row

  declare

  stara_nazwa varchar2(50);

  begin

  dbms_output.put_line('wstawion wiersz do tabeli jobs');

  stara_nazwa:=:new.job_title;

  :new.job_title:=upper(:new.job_title);

  dbms_output.put_line('stara nazwa ' || stara_nazwa || ' zmieniono na ' || :new.job_title);

  end;

  create or replace trigger custom3

  before insert on jobs

  for each row

  when (new.max_salary>10000)

  begin

  dbms_output.put_line('wstawion kasiaste stanowisko');

 

  end;

When i execute

insert into jobs values('aaa', 'bbbb', 12000, 15000);

I get nothing, then I execute

begin

dbms_output.put_line('xyz');

end;

I get

wstawion kasiaste stanowisko

wstawion wiersz do tabeli jobs

stara nazwa bbbb zmieniono na BBBB

xyz

I use sql developer.

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 20 2018
Added on Jan 1 2018
15 comments
1,010 views