1 Kings 11:34

Howbeit I will not take the whole kingdom out of his hand: but I will make him prince all the days of his life for David my servant’s sake, whom I chose, because he kept my commandments and my statutes:

God would not take the whole kingdom out of Solomon's hand at once, but would leave him as prince and ruler for all the days of his life. This sparing was for the sake of David His servant, whom He chose because David kept His commandments and His statutes. The full taking away was delayed until after Solomon's lifetime, when the kingdom would be taken from the hand of his son.

The division was to rend the kingdom and give ten tribes to Jeroboam, as declared through Ahijah. The rending was because Israel had forsaken God and worshiped Ashtoreth the goddess of the Zidonians, Chemosh the god of the Moabites, and Milcom the god of the Ammonites, and had not walked in God's ways to do what is right and to keep His statutes and judgments as David had. The promise belongs to the earlier prophecy that foretold Jeroboam's elevation to the throne, given many years before Jeroboam's apostasy when Ahijah later prophesied the ruin of his kingdom because of his sins. It also shows the Lord preserving the kingdom in Jeroboam's hand during his lifetime.