Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> IF THEN expects an SQL statement in PL/SQL?
Hi all
I'm writing a trigger, and I've got the following problem. This works:
IF monateDazwischen > 0 THEN
einfuegewert := 1010;
INSERT INTO triggertest_destination (datum) values (einfuegewert);
ELSE
einfuegewert := 2222;
INSERT INTO triggertest_destination (datum) values (einfuegewert);
END IF;
And This doesn't:
IF monateDazwischen > 0 THEN
einfuegewert := 1010;
ELSE
einfuegewert := 2222;
END IF;
It's exactly the same code, except I am not executing an SQL statement
in case 2.
Does PL/SQL expect a SQL statement in ich IF.. THEN.. ELSE clause? That's an impossible explanation to me...... Or do I really have to write a table that's just good for doing... well... nothing??
Thanks in advance for any help... Received on Thu Mar 18 1999 - 04:29:49 CST