There may have been one deliverance in particular, which the Psalmist celebrates here in the name of the Church, but he includes the many and various mercies which God had all along conferred upon his chosen people. While he takes notice of the divine interposition in their behalf, in a crisis of great mercy and distress, he suggests it as matter of comfort under trial, that their subjection to the tyranny of their enemies had been designed to prove them as silver in the furnace. At the close, he would appear to speak of himself individually, and adduces it as a proof of his integrity, that God had heard him, for God does not grant acceptance to the wicked.
To the chief musician, the Song of a Psalm.1
1 "This psalm is anonymous; nor can we, with certainty, determine to what time it relates. Venema refers it to the reign of Hezekiah, and supposes it to celebrate the deliverance which was effected by the destruction of Sennacherib's army. Rudinger is of opinion, that it celebrates the opening of the sacred temple, after the return from Babylon. It must be owned, that we have nothing but conjecture to offer on this subject; yet it appears to me that the latter of these opinions is the most probable." -- Walford.