8 When the Philistines heard that David had been anointed king over all Israel, all the Philistines went up to search for David. But David heard of it and went out against them.9 Now the Philistines had come and made a raid in the Valley of Rephaim.10 And David inquired of God, “Shall I go up against the Philistines? Will you give them into my hand?” And the Lord said to him, “Go up, and I will give them into your hand.”11 And he went up to Baal-perazim, and David struck them down there. And David said, “God has broken through[a] my enemies by my hand, like a bursting flood.” Therefore the name of that place is called Baal-perazim.12 And they left their gods there, and David gave command, and they were burned.
13 And the Philistines yet again made a raid in the valley.14 And when David again inquired of God, God said to him, “You shall not go up after them; go around and come against them opposite the balsam trees.15 And when you hear the sound of marching in the tops of the balsam trees, then go out to battle, for God has gone out before you to strike down the army of the Philistines.”16 And David did as God commanded him, and they struck down the Philistine army from Gibeon to Gezer.17 And the fame of David went out into all lands, and the Lord brought the fear of him upon all nations.