After this, David defeated the Philistines and subdued them; and he took Gath and its towns away from the Philistines.