Added checks for failUpdate and failInsert.