Reset value each year with a trigger
But the statement which extract the the year is failing I do not know why.

Change the way it is assigning the the variables. Use SELECT...INTO. Below is an example,

SELECT IF( (SELECT EXTRACT(YEAR FROM date_creation) FROM billing_invoice 
WHERE (id = @current_id)) = YEAR(CURDATE()) ,@next_id := @next_handler, @next_handler := 0001) INTO @dummy;


This is not a perfect solution in that it creates the @dummy variable, but I can't comment so I just posted it.