I\'m trying to remove a row after inserted in a temp table and I get this error:
INSERT INTO `temp_program_counter` (`id`, `program_id`) values (NULL, \'275\
You probably have already resolved this in some way but I'll post the answer anyway:
You cannot refer to the same table that triggered the trigger in a trigger (or a combination of trigger and stored procedure). This could mean an infinite loop, so sql prevents it by giving that error, resulting in always the same error.