The people crowned Josiah's younger son Jehoahaz as his successor instead of the rightful son, probably because of strong anti-Egyptian feelings. But within weeks the nation would lose control over its throne, forced to adapt a vassal king appointed by the conquering nation.
Jehoahaz was deposed by pharaoh Neco after three months and taken to Egypt as a prisoner. Eliakim his older brother was made vassal king instead, and Neco changed Eliakim' s name to Jehoiakim. Jehoiakim would reign eleven years.
God's Promissory Note
God had previously commanded that the land was to enjoy a year of rest every seventh year, a "Sabbath of the land." During that year you could pick food for individual consumption but you were not to harvest the land or cultivate the fields. God said that if the Jews failed to give the land this rest, He would force the land to have the rest He had called for by removing the people who lived upon it. For 490 years the land had not received its Sabbath years. 70 years were owed to God and He was about to claim them. See Leviticus 25-26 for details.
After the final battle of Carcemish was finished, Nebuchadnezzar came to Jerusalem. After a brief siege, Jehoiakim surrendered and was put in bronze chains to be taken to Babylon. Apparently at this time Nebuchadnezzar heard about his father's death and changed his mind about Jehoiakim, installing him back on the throne as a vassal king for the next seven years as he rushed back to take the throne before civil unrest set in back home.
Five years later, in 600BC, Jehoiakim rebelled against Nebuchadnezzar, possibly believing that Neco would win another battle against the Babylonian king. He burned the scrolls of Jeremiah and listened to the advice of his false prophets instead, who claimed that Nebuchadnezzar would leave him alone.
"Whenever Jehudi had read three or four columns of the scroll, the king cut them off with a scribe's knife and threw them into the firepot, until the entire scroll was burned in the fire. The king and all his attendants who heard all these words showed no fear, nor did they tear their clothes."
-- Jeremiah 36:23-24
They were wrong about their predictions. Jeremiah was right. Nebuchadnezzar was not about to stand for rebellion by a vassal king, and acted swiftly to set things straight. He captured Jerusalem, bound Jehoiakim in chains and led him away to Babylon, along with more of the treasures from the Temple.
The Royal Line of David Ends
Next Jehoiachin, the son of Jehoiakim was made king. He is also called "Jekoniah" and "Coniah" in different books of the Bible. His reign would be just three months and ten days.
Though his reign was short, he was filled with evil. His emphasis on idol worship and evil deeds so upset God that He pronounced a blood curse on the line of Jehoiachin, saying that none of his descendants would ever sit on the throne of David.
God said that he would treat this man, this direct royal decendant of the line of David, as if he were childless!
"As surely as I live," declares the LORD, "even if you, Jehoiachin son of Jehoiakim king of Judah, were a signet ring on my right hand, I would still pull you off. I will hand you over to those who seek your life, those you fear to Nebuchadnezzar king of Babylon and to the Babylonians. I will hurl you and the mother who gave you birth into another country, where neither of you was born, and there you both will die. You will never come back to the land you long to return to." This is what the LORD says: "Record this man as if childless, a man who will not prosper in his lifetime, for none of his offspring will prosper, none will sit on the throne of David or rule anymore in Judah."
-- Jeremiah 22:24-30
This is a significant issue, because the Messiah was to come from that same royal line, and it was long recognized that He would take the throne of David. How could God proclaim a physical end to the royal line of David and still fulfill His prophetic promise to put the Messiah on David's throne?
Compare Matthew's genealogy (of Jesus) through Joseph to Luke's genealogy through Mary. Both come from the line of David, both grant a proper title to Jesus, yet they avoid the blood curse placed on Jehoiachin.
Matthew's genealogy goes through Jehoiachin and ends with Joseph. Though the father of Jesus, he is not Christ's birth father. Thus Jesus inherits the right to the throne through his father's geneology without being blemished by the blood curse.
Luke's genealogy goes to David and then turns off slightly to move through Nathan rather than Solomon, ending up with Mary, the birth mother of Jesus. Thus both parents came from the line of king David, just as God promised. Jesus received the legal right to the throne through his father, but his blood is untouched by the curse on the line of Jehoiachin.
Jehoiachin was brought to Babylon and kept there as prisoner for 37 years. He was released on the 27th day of the 12th month and enjoyed dining at the Babylonian king's table for the rest of his life, but as prophecied he never returned to Israel.