I was wondering if there is a midrash that explains this contradictions int he tanach: 2 Chronicles 22:2: Forty and two years old was Ahaziah when he began to reign, and he reigned one year in Jerusalem. His mother’s name also was Athaliah the daughter of Omri. 2 Kings 8:26: Two and twenty years old was Ahaziah when he began to reign; and he reigned one year in Jerusalem. And his mother’s name was Athaliah, the daughter of Omri king of Israel. Twenty two or forty two?
The Tosefta Sotah 12:13 picks up on this contradiction and suggests that the forty two years listed in Chronicles do not all belong to Ahazya but are the years since the final decree over the royal house of David to perish. The Radak suggests that twenty two years old Ahazya ruled during the Time of his father who was too sick to handle the kingdom on his own, twenty years later when he was forty two his father king Yehoram dies and he is inherits the throne.