19
Some time later, Nahash, king of the Ammonites, died and his son succeeded him. David said, “I will be kind to Hanun, son of Nahash, for his father was kind to me.” So David sent messengers to comfort him over his father's death. David's ambassadors arrived in the land of the Ammonites and went comfort Hanun. But the Ammonite princes said to Hanun, “Do you really think that David is honoring your father by sending comforters to you? Haven't these ‘comforters’ only come to spy out the land to find ways to conquer it?” So Hanun detained David's ambassadors and had them shaved, and their robes cut off at the buttocks.*To humiliate and shame them, and to send a message of defiance back to David. Then he sent them back.
A message was sent to David to explain what had happened to the men. David then sent messengers to the men to tell them, “Stay at Jericho until your beards grow, and then you can come back.”
Then the Ammonites realized that they had really been offensive to David So Hanun and the Ammonites sent a thousand talents of silver to hire chariots and charioteers from Aram-naharaim, Aram-maacah, and Zobah. They also hired 32,000 chariots and the king of Maacah with his army. They came set up camp near Medeba. The Ammonites were also called up from their towns and prepared for battle.
When David learned of this, he sent Joab and the entire army to confront them. The Ammonites set up their battle lines near the town entrance, while the other kings who had joined them took up positions in the open fields.
10 Joab realized he would have to fight both in front of him and behind him, he chose some of Israel's best troops and he took charge of them to lead the attack the Arameans. 11 He put the rest of the army under the command of Abishai, his brother. They were to attack the Ammonites. 12 Joab told him, “If the Arameans are stronger than me, you come and help me. If the Ammonites are stronger than you, I'll come and help you. 13 Be brave, and fight your best for our people and the towns of our God. May the Lord do what he sees as good!”
14 Joab attacked the Arameans with his forces and they ran away from him. 15 When the Ammonites saw that the Arameans had run away, they also ran away from Abishai, Joab's brother, and retreated into the town. So Joab went back to Jerusalem.
16 As soon as the Arameans saw they had been defeated by the Israelites so they sent for reinforcements from the other side of the Euphrates River, under the leadership of Shobach, commander of Hadadezer's army.
17 When this was reported to David, he assembled all Israel together. He crossed the Jordan and approached the Aramean army, drawing up his forces in battle line against them. When David engaged in battle with them they fought with him. 18 But the Aramean army ran away from the Israelites, and David killed 7,000 charioteers and 40,000 infantry, as well as Shobach, their army commander. 19 When Hadadezer's allies realized that they had been defeated by Israel, they made peace with David and became subject to him. As a result, the Arameans didn't want to help the Ammonites any more.

*19:4 To humiliate and shame them, and to send a message of defiance back to David.