Then David said, "I'll show kindness to Hanun son of Nahash, just as his father showed kindness to me." So David sent his emissaries to console Hanun concerning his father. However, when they arrived in the land of the Ammonites,
the Ammonite leaders said to Hanun their lord, "Just because David has sent men with condolences for you, do you really believe he's showing respect for your father? Instead, hasn't David sent his emissaries in order to scout out the city, spy on it, and overthrow it?"
When this was reported to David, he sent [someone] to meet them, since they were deeply humiliated. The king said, "Stay in Jericho until your beards grow back; then return."
When the Ammonites realized they had become repulsive to David, they hired 20,000 foot soldiers from the Arameans of Beth-rehob and Zobah, 1,000 men from the king of Maacah, and 12,000 men from Tob.
The Ammonites marched out and lined up in battle formation at the entrance to the city gate while the Arameans of Zobah and Rehob and the men of Tob and Maacah were in the field by themselves.
When Joab saw that there was a battle line in front of him and another behind him, he chose some men out of all the elite troops of Israel and lined up in battle formation to engage the Arameans.
"If the Arameans are too strong for me," Joab said, "then you will be my help. However, if the Ammonites are too strong for you, I'll come to help you.
When the Ammonites saw that the Arameans had fled, they too fled before Abishai and entered the city. So Joab withdrew from the attack against the Ammonites and went to Jerusalem.
Hadadezer sent [messengers] to bring the Arameans who were across the Euphrates River, and they came to Helam with Shobach, commander of Hadadezer's army, leading them.
When this was reported to David, he gathered all Israel, crossed the Jordan, and went to Helam. Then the Arameans lined up in formation to engage David in battle and fought against him.
But the Arameans fled before Israel, and David killed 700 of their charioteers and 40,000 foot soldiers. He also struck down Shobach commander of their army, who died there.
When all the kings who were Hadadezer's subjects saw that they had been defeated by Israel, they made peace with Israel and became their subjects. After this, the Arameans were afraid to ever help the Ammonites again.