Now these things which happened to our ancestors are illustrations of the way in which God works, and they were written down to be a warning to us who are the heirs of the ages which have gone before us. 1 Corinthians 10:11, Phillips.
The murmurings of ancient Israel and their rebellious discontent, as well as the mighty miracles wrought in their favor and the punishment of their idolatry and ingratitude, are recorded for our benefit. The example of ancient Israel is given as a warning to the people of God, that they may avoid unbelief and escape His wrath. If the iniquities of the Hebrews had been omitted from the Sacred Record, and only their virtues recounted, their history would fail to teach us the lesson that it does....
If God's people would recognize His dealings with them and accept His teachings, they would find a straight path for their feet and a light to guide them through darkness and discouragement. David learned wisdom from God's dealings with him and bowed in humility beneath the chastisement of the Most High. The faithful portrayal of his true state by the prophet Nathan made David acquainted with his own sins and aided him to put them away. He accepted counsel meekly and humiliated himself before God. “The law of the Lord,” he exclaims, “is perfect, converting the soul.”
Repentant sinners have no cause to despair because they are reminded of their transgressions and warned of their danger. These very efforts in their behalf show how much God loves them and desires to save them. They have only to follow His counsel and do His will, to inherit eternal life. God sets the sins of His erring people before them, that they may behold them in all their enormity under the light of divine truth. It is then their duty to renounce them forever.
God is as powerful to save from sin today as He was in the times of the patriarchs, of David, and of the prophets and apostles. The multitude of cases recorded in sacred history where God has delivered His people from their own iniquities should make the Christian of this time eager to receive divine instruction and zealous to perfect a character that will bear the close inspection of the judgment.2Testimonies for the Church 4:11-15.
From Conflict and Courage - Page 8