hello ,
(begginer of SQL)
i have to make one pro. in which
i have to use trigger which will fire before inserting into table
and convert the name into upper case but i don't what is the prob.
with the code pls provide ur suggetion
my table attributes are
stu (sno number(6),sname varchar(12),class varchar(12) );
create or replace trigger trg27
before insert on stu
for each row
declare
sname1 stu.sname%type;
sno1 stu.sno%type;
class1 stu.class%type;
begin
sno1:=:new.sno;
sname1:=:new.sname;
sname1:=upper(sname1);
class1:=:new.class;
exception
when others then
dbms_output.put_line('Error is occured..!!');
insert into stu values(sno1,sname1,class1);
end;