I'm trying to write an update trigger that will Design_Update_Status to Customized when a date is entered in Custom_Design_Update_Date field and if nothing is entered that field it should update Design_Update_Status to Standard.
As of now i am using a trigger and this doesnot update the status correctly.
IF NEW.Custom_Design_Update_Date = '' THEN SET NEW.Design_Update_Status = 'STANDARD'; else SET NEW.Design_Update_Status = 'CUSTOMIZED'; END IF;
tried a lot in this, cant figure out a solution. help needed in this regard.