MYSQL trigger generates a 1329 error
===

I have two tables,  one that list entries and another that has results.

I am trying to create a After trigger on the entries table that creates a corresponding record in the results table, IF all of the entry information for that record is complete. The column fleet is not NULL if the results table should be created.

    IF (NEW.fleet IS NOT NULL) THEN

    INSERT INTO race_results (race_id,yr,race_num,owner_id,checked_in,flt)VALUES(NEW.race_id,NEW.yr,NEW.race_num,NEW.owner_id,"N",NEW.fleet)ON DUPLICATE KEY UPDATE flt =NEW.fleet;

    END IF

This code runs fine except when it runs on a row with NEW.fleet equals NULL it throws a #1329 error.

Thanks in advance.

