When the Ammonites realized that they had become a stench in David's nostrils, Hanun and the Ammonites sent a thousand talents of silver to hire chariots and charioteers from Aram Naharaim, Aram Maacah and Zobah.
They hired thirty-two thousand chariots and charioteers, as well as the king of Maacah with his troops, who came and camped near Medeba, while the Ammonites were mustered from their towns and moved out for battle.
On hearing this, David sent Joab out with the entire army of fighting men.
The Ammonites came out and drew up in battle formation at the entrance to their city, while the kings who had come were by themselves in the open country.
Joab saw that there were battle lines in front of him and behind him; so he selected some of the best troops in Israel and deployed them against the Arameans.
He put the rest of the men under the command of Abishai his brother, and they were deployed against the Ammonites.
Joab said, "If the Arameans are too strong for me, then you are to rescue me; but if the Ammonites are too strong for you, then I will rescue you.
Be strong and let us fight bravely for our people and the cities of our God. The LORD will do what is good in his sight."
Then Joab and the troops with him advanced to fight the Arameans, and they fled before him.
When the Ammonites saw that the Arameans were fleeing, they too fled before his brother Abishai and went inside the city. So Joab went back to Jerusalem.
After the Arameans saw that they had been routed by Israel, they sent messengers and had Arameans brought from beyond the River, with Shophach the commander of Hadadezer's army leading them.
When David was told of this, he gathered all Israel and crossed the Jordan; he advanced against them and formed his battle lines opposite them. David formed his lines to meet the Arameans in battle, and they fought against him.
But they fled before Israel, and David killed seven thousand of their charioteers and forty thousand of their foot soldiers. He also killed Shophach the commander of their army.
When the vassals of Hadadezer saw that they had been defeated by Israel, they made peace with David and became subject to him. So the Arameans were not willing to help the Ammonites anymore.
In the spring, at the time when kings go off to war, Joab led out the armed forces. He laid waste the land of the Ammonites and went to Rabbah and besieged it, but David remained in Jerusalem. Joab attacked Rabbah and left it in ruins.
David took the crown from the head of their king--its weight was found to be a talent of gold, and it was set with precious stones--and it was placed on David's head. He took a great quantity of plunder from the city
and brought out the people who were there, consigning them to labor with saws and with iron picks and axes. David did this to all the Ammonite towns. Then David and his entire army returned to Jerusalem.
In the course of time, war broke out with the Philistines, at Gezer. At that time Sibbecai the Hushathite killed Sippai, one of the descendants of the Rephaites, and the Philistines were subjugated.
In another battle with the Philistines, Elhanan son of Jair killed Lahmi the brother of Goliath the Gittite, who had a spear with a shaft like a weaver's rod.
In still another battle, which took place at Gath, there was a huge man with six fingers on each hand and six toes on each foot--twenty-four in all. He also was descended from Rapha.
When he taunted Israel, Jonathan son of Shimea, David's brother, killed him.
These were descendants of Rapha in Gath, and they fell at the hands of David and his men.
Satan rose up against Israel and incited David to take a census of Israel.
So David said to Joab and the commanders of the troops, "Go and count the Israelites from Beersheba to Dan. Then report back to me so that I may know how many there are."
But Joab replied, "May the LORD multiply his troops a hundred times over. My lord the king, are they not all my lord's subjects? Why does my lord want to do this? Why should he bring guilt on Israel?"
The king's word, however, overruled Joab; so Joab left and went throughout Israel and then came back to Jerusalem.
Joab reported the number of the fighting men to David: In all Israel there were one million one hundred thousand men who could handle a sword, including four hundred and seventy thousand in Judah.
But Joab did not include Levi and Benjamin in the numbering, because the king's command was repulsive to him.
This command was also evil in the sight of God; so he punished Israel.
Then David said to God, "I have sinned greatly by doing this. Now, I beg you, take away the guilt of your servant. I have done a very foolish thing."
The LORD said to Gad, David's seer,
"Go and tell David, 'This is what the LORD says: I am giving you three options. Choose one of them for me to carry out against you.' "
So Gad went to David and said to him, "This is what the LORD says: 'Take your choice:
three years of famine, three months of being swept away before your enemies, with their swords overtaking you, or three days of the sword of the LORD --days of plague in the land, with the angel of the LORD ravaging every part of Israel.' Now then, decide how I should answer the one who sent me."
David said to Gad, "I am in deep distress. Let me fall into the hands of the LORD, for his mercy is very great; but do not let me fall into the hands of men."