-
Trigger Problem
I got a schema called Gary and another called SS
I m creating this trigger by loggin on to SS on Gary.G_Diary
what privileges do i need to have if any required.
If an insert is performed on Gary.G_DIARY i m inserting into my local table. I want to acheive this...but i m getting problems with :new and ld variables.
:new.gary.g_diary.columnname (can this be given)
Below is the code, Could anyone pl let me know whas wrong here.
Create or Replace Trigger Gdiary_ict
After Insert or Update or Delete on GARY.G_DIARY
for each row
declare
v_msg varchar2(100);
all_day varchar2(1);
recs number(8);
Begin
if inserting then
insert into G_DIARY_local (event_id,room_no,event,event_date,all_day,start_hour,start_mins)
values(ghall_eventdiary.nextval,:NEW.G_DIARY.ROOM_NO,:NEW.G_DIARY.EVENT,
:NEW.g_diary.event_date,'Y',:NEW.G_DIARY.HOUR_VALUE,:NEW.G_DIARY.HOUR_MINS);
end if;
end;
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|