The heading for Psalm 52 gives the historical setting as one of the most bitter experiences in the life of David: "When Doeg the Edomite had gone to Saul and told him: 'David has gone to the house of Ahimelech.’"

Teaching is not the only thing David wants to do however. He also wants to praise God rightly. He wants to praise God out of a broken spirit and a contrite heart.

Restore the joy of your salvation. The third of David's requests in this section is that God restore the joy of his salvation. It is important to note that David is not praying that God would restore his salvation, as if he had lost it and needed to get it back again. It is not the salvation he has lost, but the joy of it. As long as he was living in sin he had no joy. His fellowship with God was broken. Now that he has repented of his sin, found cleansing and is seeking a renewed spirit, he wants to have that joy again.

John Calvin believed in eternal security, of course. So when he came to this verse he argued that David's prayer that God not take away the Holy Spirit showed that he still possessed the Holy Spirit. Hence, even his great sins of adultery and murder had not threatened David's perseverance in grace. The bottom line of Calvin's answer to the apparent problem of this verse would seem to be that David did not need to pray as he did, since the removal of God's Spirit from a born again son or daughter of God is an impossibility. Calvin wrote, "It is natural that the saints, when they have fallen into sin, and have thus done what they could to expel the grace of God, should feel an anxiety upon this point; but it is their duty to hold fast the truth, that grace is the incorruptible seed of God, which can never perish in any heart where it has been deposited.”2