Im creating my first sql trigger,
CREATE OR REPLACE TRIGGER totalsalary AFTER INSERT ON Employee FOR EACH ROW WHEN ( NEW.Dno IS NOT NULL ) BEGIN UPDATE Department SET totalSalary totalSalary + NEW.salary WHERE Dno = NEW.Dno; END ;
but i got this error message and i dont know how to fix it
Error at line 3: PL/SQL: ORA-00927: missing equal sign 1. CREATE OR REPLACE TRIGGER SueldoTotal 2. AFTER INSERT ON EMPLEADO 3. FOR EACH ROW 4. WHEN ( NEW.Dno IS NOT NULL ) 5. BEGIN