Hi Walter and rest of the list,
sorry that I forgot to mention this in my last posting, I already
tested your version and this produces the error:
General error;-7045 POS(243) Parameter spec not allowed
so, I have no idea how to check this NEW value in my insert trigger.
Following code is not working, but how ???
1.)
create trigger tr_blub for table1 after insert execute
(
if NEW.comment <> 'default comment' then
...
)
2.)
create trigger tr_blub for table1 after insert execute
(
if :NEW.comment <> 'default comment' then
...
)
3.)
create trigger tr_blub for table1 after insert execute
(
if comment <> 'default comment' then
...
)
thanks in advance ..:GERD:..
-----Urspr�ngliche Nachricht-----
Von: Walter Link [mailto:[EMAIL PROTECTED]
Gesendet: Freitag, 5. September 2003 19:07
An: Gerd K�nig
Betreff: Re: check NEW in insert trigger
Hallo Herr K�nig,
Sie sollten den Doppelpunkt vor dem NEW nicht vergessen:
if :New.comment <> ...
Am Freitag, 5. September 2003 16:12 schrieb Gerd K�nig:
> Hi,
>
> I'm a little bit confused...(O.K. it's friday ;-))
> I've created a after insert trigger, and I want to check
> one column of the new data set if it is equal to some string.
> But I cannot manage this...
>
> 1.)
> code:
> create trigger tr_blub for table1 after insert execute
> (
> VAR company integer;
> if NEW.comment <> 'default comment' then
> ....
>
> result:
> NEW.comment is marked RED.
> General error;-8010 POS(128) Table name must be in from list.
>
> 2.)
> code:
> if comment <> 'default comment'
> result:
> General error;-4024 POS(128) Unknown name:COMMENT
>
>
> so, how to check this value ????
> (table1 really has a column named 'comment')
>
> thanks in advance ..:GERD:..
>
>
> _______________________________________________
> sapdb.general mailing list
> [EMAIL PROTECTED]
> http://listserv.sap.com/mailman/listinfo/sapdb.general
_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general