Salve a tutti,
ho un problema con il seguente trigger:
L'errore in questione è:Codice:CREATE TRIGGER prenotazioni_insert_controllo AFTER INSERT ON Prenotazione FOR EACH ROW BEGIN IF NEW.Giorno < CURDATE() THEN DELETE FROM Prenotazione WHERE NEW.Giorno=Giorno and NEW.ID_Utente=ID_Utente and NEW.ID_Pasto=ID_Pasto; END IF; END;
Come posso risolvere?Grazie a tutti.#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 7

LinkBack URL
About LinkBacks
