'A prayer of one afflicted, when he is faint', this psalm expresses the agony of someone experiencing what we would today call depression. Every day seems empty; his sorrow feels physically painful [v.3]; his heart loses all vigour [v.4]; he forgets to eat and loses weight [v.4-5]; in sleepless nights he feels horribly alone, only able to think about those who are against him [v.7-8]; even pleasures loose their flavour [v.9]; he feels abandoned by God [v.10]: life is pointless [v.11].
What hope can there possibly be in such sorrow? In the second half of this psalm, this broken-hearted man lifts his sights towards God and His great purposes for 'Zion', His people [v.12-28]. He takes in the big picture of God’s purposes, which cannot fail. Not that this is some kind of 'quick fix' for his distress [see v.23-24]. But it reaches for comfort in the truth that God's plan for Zion includes the ultimate good for each of her members. Even their distress is part of God's larger scheme: their faithful endurance is not, in fact, meaningless.
Godly people in the Bible got depressed. Even Paul, who wrote 'Rejoice in the Lord always' [Phil.4:4] also wrote 'We were so utterly burdened beyond our strength that we despaired of life itself' [2Cor.1:8]. Christian joy is not a denial of life’s very real pains, but a recognition that God’s overall plans for His people will prevail, that His love is eternal, and that, in the end, as one medieval saint wrote:
All shall be well and all shall be well and all manner of thing shall be well.