In Surah Baqarah near ayah 250, it reaches the conclusion of the battle of talut and jalut (talut is the Arabic for Saul, the king of Israel).
If your not familiar with the story Talut wanted to test his people’s discipline and ability to follow instructions before proceeding in battle, so he told his people Allah will be testing you with the river, so do not drink from it. Only a few had obeyed his order, and they were among the ones who continued marching with Talut.
The English translation of Surah Baqarah ayah 249 reads,
“And when Saul went forth with the soldiers, he said, “Indeed, Allah will be testing you with a river. So whoever drinks from it is not of me, and whoever does not taste it is indeed of me, excepting one who takes [from it] in the hollow of his hand.” But they drank from it, except a [very] few of them.
Once their army had crossed over the water and stood in front of jalut (goliath) they could see they were greatly outnumbered. From afar it seemed as though there was a single row of army men but they couldn’t properly gauge the army size, once they were close they could not see the end of the enemy, it appeared only grow larger and larger the closer they got.
Continuation of ayah 249,
Then when he had crossed it along with those who believed with him, they said, “There is no power for us today against Goliath and his soldiers.” But those who were certain that they would meet Allah said, “How many a small company has overcome a large company by permission of Allah . And Allah is with the patient.”
Now, the training test with the water was done, they had crossed the river and now face the large army of Goliath. They did not turn their backs, they summoned courage by reciting the dua revealed in Surah Baqarah ayah 250 before entering battle.
Rabbana afrigh alayna sabran Full Dua With Meaning:
In arabic this dua for sabr is given in Baqarah ayah 250,
رَبَّنَا أَفْرِغْ عَلَيْنَا صَبْراً وَثَبِّتْ أَقْدَامَنَا وَانصُرْنَا عَلَى القَوْمِ الكَافِرِينَ
Rabbana afrigh alayna sabran wa thabbit aqdamana wansurna alal-qawmil-kafirin
English Meaning: Our Lord, pour upon us patience and plant firmly our feet and give us victory over the disbelieving people.
This beauty of this dua is that it asks Allah to drench us in sabr, i.e. to completely empty or pour upon us patience. As mentioned in ayah 249, Allah is with those who have sabr, and a small army who has Allah can overcome a larger one.
It continues by then requesting Allah to ‘plant our feet firmly’, which could mean give us strength, bravery, and courage. These are all things necessary to combat the enemy, to stand your ground and to not be easily swayed. To have a good foundation requires sturdiness, otherwise you would just topple over and allow people to walk all over you. So Allah, we ask for you to plant firmly our feet.
The last request made by the people was victory, specifically victory of the disbelieving people, in this case the jalut. Ayah 251 concludes the outcome of the battle,
“So they defeated them by permission of Allah, and David killed Goliath, and Allah gave him the kingship and prophethood and taught him from that which He willed. And if it were not for Allah checking [some] people by means of others, the earth would have been corrupted, but Allah is full of bounty to the worlds.”