When Solomon became old, his wives shifted his allegiance to other gods; he was not wholeheartedly devoted to the Lord his God, as his father David had been.
He followed in his father Asa’s footsteps and was careful to do what the Lord approved. (22:44) However, the high places were not eliminated; the people continued to offer sacrifices and burn incense on the high places.
Solomon demonstrated his loyalty to the Lord by following the practices of his father David, except that he offered sacrifices and burned incense on the high places.
Certainly the Lord watches the whole earth carefully and is ready to strengthen those who are devoted to him. You have acted foolishly in this matter; from now on you will have war.