All four Gospels tell us about Jesus' entry into Jerusalem, five days before his death. And three of them tell us that the crowd greeted him with cries of "Hosanna".
The exception is the Gospel of Luke. Luke's Gospel forms a careful plea to someone called Theophilus about the Christian faith. Because Theophilus was probably not a Jew, but someone fairly exalted in the Roman empire, the word hosanna would have meant nothing to him. So the writer adds a different greeting, "Peace in heaven, and glory in the highest heaven", recalling the words of the angels at the beginning of his Gospel.
Jewish readers, though, would have recognized the cry as a call from one of the Psalms, just as they would have recognized Jesus' cry from the cross, Eli, Eli, lama sabachthani? as the opening words of Psalm 22 (and just as we today use Latin words like Magnificat or Te Deum to recall Christian songs). Hosanna is the word translated "Save us, we beseech you" at verse 25 of Psalm 118.
You may wonder why we need five words in English to translate one word (though the "we beseech you" bit, na, is normally written as a separate word in Hebrew). But this is just because we have no English word meaning "bring salvation". The important question is who is bringing the salvation, and what the salvation consists of.
The Psalm is quite clear that it is God who is bringing salvation, and the second half of Ps.118:25 echoes the call, "Lord, bring us success". What kind of success, though? The first part of the Psalm is a vivid depiction of the king, standing on behalf of the people, surrounded by enemies ("like bees, like a fire of thorns"), and gaining victory, thanks to God. "The Lord is my strength and my might, and has become my salvation."
The Psalm seems to have been sung as part of a procession celebrating a victory. The procession halts at the Temple gates: "This is the gate of the Lord; the righteous shall enter through it." (v.20). The sight of the keystone of the arch is another reminder of victory over opposition: "The stone that the builders rejected has become the chief cornerstone." It is clear where the victory has come from: "This is the Lord's doing; it is marvellous in our eyes." And the king enters the Temple: "Blessed is the one who comes in the name of the Lord" (v.26)
The Psalm would have been in people's minds at the time because it was the last of the Hallel (or "praise") Psalms which were sung at the Passover (Jesus and the disciples would have sung it at the Last Supper (Mt 26:30)). The waving of branches was associated with the other time it was sung, at the Feast of Booths or Tabernacles, the harvest festival at the autumn equinox. It was a song of celebration, of rejoicing. It was also a song of expectation.
The crowd witnessing Jesus' entry into Jerusalem, riding on a donkey, fulfilling Zechariah's prophecy, would have recalled Psalm 118 as an expectation of victory - victory over the occupying Roman rulers. They did not see that the rejection they were recalling was the rejection that the chief priests and they themselves would pronounce only a few days later. They did not realize that the cornerstone would not be a political liberator, but someone who would liberate them from the power of sin and death. They did not realize how soon their Hosanna would turn to Crucify.
The joyful expectation in the Psalm has changed the meaning of Hosanna from a plea for salvation to a song of praise. This change had already happened in Jesus' day, so Matthew could report the crowd's words as "Hosanna to the Son of David... Hosanna in the highest heaven". Grammatically this makes no sense, but it is clear what the sense is. It is an expectation of joy. It is an expression before Jesus' suffering and death of the Alleluias we sing at Easter. Blessed is he who comes in the name of the Lord. Hosanna in the highest!
HD