defined error codes in case of insertion failure