1 Kings 11:15-17
11:15 During David’s campaign against Edom, Joab, the commander of the army, while on a mission to bury the dead, killed every male in Edom.
11:16 For six months Joab and the entire Israelite army stayed there until they had exterminated every male in Edom.
11:17 Hadad, who was only a small boy at the time, escaped with some of his father’s Edomite servants and headed for Egypt.