Why does a prayer for rescue say the goal is praising God? Does God need compliments?
Read the end of the first verse again. We ask to be saved, gathered and rescued, and the reason given is: to give thanks to Your holy name and to take pride in praising You. The goal named is not comfort. It is thanks. That can sound like God needing compliments.
Radak (Rabbi David Kimchi, a Bible commentator in France, around 1200) reads the verse as the people in exile speaking: when You gather us, we will thank Your holy name. He also says what "Your praise" means. It is the acts of kindness God has done for us, and we praise Him for them. On his reading, praise means thanks for specific things that happened.
The word lehishtabeach can be read as "to take pride." Metzudat David (a commentary on the Prophets and Writings from the 1700s) says it means to praise ourselves in Your praise. The more praise there is in You, the more our own praise grows, because You chose us. On the same verse in Divrei HaYamim he says it counts as praise to cling to Hashem, who is praised so highly.
Ralbag (Rabbi Levi ben Gershom, a Bible commentator in Provence in the 1300s) puts it in order. We ask for rescue so that we may thank Your holy name and take pride in Your praise, when You settle the people who cling to You on their inheritance, as You promised in the Torah and through the prophets.
Ibn Ezra (another Bible commentator, from the 1100s) says the next verse belongs to the same thought. In his view, once we have been saved and are taking pride in Your praise, then all of us will say that Hashem is blessed from forever to forever.
In these comments, praise comes after rescue. It is what the rescued people do. None of them says here that God needs it.
Radak on Tehillim 106:47,Metzudat David on Tehillim 106:47 and on Divrei HaYamim I 16:35,Ralbag on Divrei HaYamim I 16:35,Ibn Ezra on Tehillim 106:48The prayer says God "dwells in Jerusalem." Isn't God everywhere?
King Shlomo (Solomon) asked this long ago. When he finished building the Temple, he said: "But will God really live on earth? The heavens and the highest heavens cannot hold You, so how much less this house I have built." (Melachim I, the First Book of Kings, 8:27)
Radak (Rabbi David Kimchi, a Bible commentator in France, around 1200) takes the question seriously. It cannot be believed that God sits on earth among people, he writes, because no place could hold God: "You are the place of the world, and the world is not Your place." So the house is a figure of speech. Shlomo is asking that God's will and glory be found there, to hear the prayers said in it.
A few verses later Shlomo says that God hears from "the place where You sit, in heaven" (8:30). The Temple is where people direct their prayer. Heaven is where God hears it.
Now our line, Tehillim 135:21: "Blessed is Hashem from Zion, who dwells in Jerusalem." It says from Zion, not only in Zion. Radak on that verse: from Zion because the Presence of God rests in Jerusalem, and from there teaching goes out to everyone, so that they will fear Him and bless Him. Yeshayahu (Isaiah) has the same picture: "From Zion Torah goes out" (2:3). Metzudat David (a commentary on the Prophets and Writings from the 1700s) says God pours out the light of His Presence from Zion.
Put together, these commentators do not say God is stuck in one city. They say God is the place of the whole world, and Jerusalem is where the Presence is found and where teaching starts. Radak on Melachim adds one more piece. God wants to hear anyone, anywhere, who calls out with a whole heart. What Shlomo asked was that this one place help the person praying there, as if the house were an angel speaking up for them.
Melachim I 8:27 and 8:30,Radak on Melachim I 8:27,Radak and Metzudat David on Tehillim 135:21,Yeshayahu 2:3We ask to be saved every day. Is there supposed to be a day when we stop?
The last verses of this prayer are the end of Tehillim 72, a psalm that begins "Of Shlomo." The next line in Tehillim, which the siddur does not include, says: "The prayers of David son of Yishai are ended." (72:20) The commentators ask what that means.
Radak (Rabbi David Kimchi, a Bible commentator in France, around 1200) passes on a reading from his father. If the psalm is about the King Messiah, then when all these comforts are complete, "the prayers of David are ended." The word is prayers, not songs or thanks. Radak says that means prayers for atonement, forgiveness and rescue. Once the Messiah, a descendant of David, is reigning, no one will need those, because everything will already be theirs.
Other commentators read it more plainly. Rashi (the best-known Bible commentator, in France in the 1000s) gives two options. One is that the Rabbis took the word to mean "all of these," so every psalm in the book is counted as David's, even ones by others. The other is that it simply means finished, and that it seems David said this psalm in his old age, when he made Shlomo king. Metzudat David agrees about his old age, and adds that the line is not at the end of the book because David chose to end the book with Halleluyahs.
Ibn Ezra lists a few readings and then quotes Rabbi Yehudah Halevi, who says it is only the first scribe's way of marking that a book has ended.
So there are at least three answers: a future time when asking is no longer needed, a plain "finished" in David's old age, and a scribe's end mark. Whichever is right, we still say the prayer. Radak's comment on the first verse in Divrei HaYamim (Chronicles) is that David told the people to pray it every day for the gathering that was still to come. The Hodu page tells that story.
Tehillim 72:1 and 72:20,Radak, Rashi, Ibn Ezra and Metzudat David on Tehillim 72:20,Radak on Divrei HaYamim I 16:35