When the Philistines heard that David had been anointed king over all Israel, they all marched up to find him. David heard this and went out to confront them.