So all the elders of Israel came to the king to Hebron; and David made a covenant with them in Hebron before Yahweh; and they anointed David king over Israel, according to the word of Yahweh by Samuel.
Now the twofold commission of God to David. Number one: you shall feed my people. And, you shall be ruler over them. David was called a man after God's own heart. Because David had the heart of a shepherd. And would to God that every leader over the people had the heart of a shepherd. He was a shepherd made king. But coming from that background he made an ideal king. Because his interest was always in the sheep. And of course, the primary need of the sheep is to be fed.