Vs. 1-6 praise God for all David has already received;
Vs. 7-13 show David’s confidence in God’s defense.
It does no good to continually request favors of God unless, and until, one praises God for what has already been done! David’s joy and reason to rejoice are because God has already: vs.2) granted his heart’s desire and voiced request; v.3) met him with “blessings of goodness” including his gold crown; v.4) given him length of life; v.5) placed “honor and majesty” upon him; v.6) given David much for which to praise God. All of these would be fulfilled in Jesus Christ (2 Samuel 7:8-17; Acts 2:22-36), but David would not even be king without the blessings of God. Wicked Nebuchadnezzar, king of Babylon, learned this the hard way (Daniel 4:28-37), and Jesus said as much to the Roman Governor, Pontius Pilate (John 19:10-12; Luke 3:1; Matthew 27:2).
In His pattern for prayer, Jesus taught disciples to “hallow” God’s name and His Will before any personal request. The Apostle Paul taught “the saints and faithful brethren in Christ who are in Colosse” (Colossians 1:2) to: “Continue earnestly in prayer, being vigilant in it with thanksgiving” (Colossians 4:2).
That God had “given him his heart’s desire” or “not withheld the request of his lips” does not picture God as some “Santa Claus” but rather pictures David as a knowledgeable believer. David knew what requests were within God’s Will to grant. Requests given to God must NOT be contrary to His Will. Even in the New Testament, those in covenant relationship with God must make submissive requests: “And whatever we ask we receive from Him, because we keep His commandments and do those things that are pleasing in His sight” (1 John 3:22). “Now this is the confidence that we have in Him, that if we ask anything according to His will, He hears us” (1 John 5:14). Clearly, God’s Will must come before our requests, as Jesus showed: “He went a little farther and fell on His face, and prayed, saying, ‘O My Father, if it is possible, let this cup pass from Me; nevertheless, not as I will, but as You will’” (Matthew 26:39). All of our plans must be submitted to God’s Will (James 4:13-15).
Psalm 21:7-12 show that David’s enemies were God’s enemies and David left them in God’s Hands to be dealt with justly. In the Old Testament (Deuteronomy 32:35) and in the New (Romans 12:17-21), God still reserves “vengeance” for Himself against His enemies. God is to be praised for whenever He determines to act (Psalm 21:13; 2 Thessalonians 1:7-9).