2 Chronicles 20:20-22 New Revised Standard Version (NRSV)
20 They rose early in the morning and went out into the wilderness of Tekoa; and as they went out, Jehoshaphat stood and said, “Listen to me, O Judah and inhabitants of Jerusalem! Believe in the Lord your God and you will be established; believe his prophets.” 21 When he had taken counsel with the people, he appointed those who were to sing to the Lord and praise him in holy splendor, as they went before the army, saying,
“Give thanks to the Lord,
22 As they began to sing and praise, the Lord set an ambush against the Ammonites, Moab, and Mount Seir, who had come against Judah, so that they were routed.