Q. I often hear people say that when Jesus cried out on the cross “My God, my God, why have you forsaken me?” this was a poignant expression of his suffering and abandonment. But given how well Jesus knew the Scriptures, and how strongly the whole of Psalm 22 describes him and his situation, didn’t he likely have the whole psalm in mind? If so, you could equally see his cry as conveying triumph through suffering. When I thought of this it changed my whole view of the crucifixion.

There’s an extensive discussion in Session 8 of the Psalms study guide (pages 52-53) of how Jesus appealed on the cross to Psalm 22.
In my view, the best understanding of what was happening when Jesus cried out “My God, my God, why have you forsaken me?” recognizes both the sense of abandonment he was expressing immediately through these words and the sense of faith and trust that’s articulated over the course of Psalm 22, to which he was indeed alluding in its entirety.
In other words, in our interpretations we need to honor what Jesus was experiencing in the moment, but we also need to recognize that he was giving voice to that experience through the words of an ancient inspired song of faith. Jesus was taking his place in the long line of Israelites who used the psalms, written centuries earlier for other occasions, to express what was happening in his own relationship with God. The Psalms were gathered into a collection and made part of the Bible precisely because people had been using them in this way for so long.
Psalm 22 was probably originally written by someone who had a deadly illness. However, the uncanny resemblance between what the psalmist describes and the experience of crucifixion, unknown at the time the psalm was written, has convinced many that the inspired writer was given an advance glimpse of Jesus’ sufferings on the cross. In that case this would be a Messianic psalm that speaks as much about the coming Messiah as about the original circumstances of the author.
What we can say for certain is that just as the people of Israel looked back to earlier songs (the psalms) to express their own spiritual experiences, the psalmists themselves also looked forward, as authors like this one express the hope that their words will be used by later generations. Psalm 22 is a classic psalm of supplication that moves from a cry for help to a statement of trust, and after a description of troubles and petition makes a vow of praise that envisions people in the future all over the world hearing about God and worshiping him. Jesus fulfilled this vision by creating a worldwide community of followers through his life and ministry, his death on the cross, and his resurrection and ascension. So the psalmist gave Jesus some words through which to express his most vital spiritual experience, and Jesus in turn gave those words the most marvelous fulfillment that could be imagined.