During the reign of David, there was a famine1 for three successive years; so David sought2 the face of the LORD. The LORD said, "It is on account of Saul and his blood-stained house; it is because he put the Gibeonites to death."
References for 2 Samuel 21:1
The king summoned the Gibeonites3 and spoke to them. (Now the Gibeonites were not a part of Israel but were survivors of the Amorites; the Israelites had sworn to [spare] them, but Saul in his zeal for Israel and Judah had tried to annihilate them.)
References for 2 Samuel 21:2
David asked the Gibeonites, "What shall I do for you? How shall I make amends so that you will bless the LORD's inheritance?"4
References for 2 Samuel 21:3
The Gibeonites answered him, "We have no right to demand silver or gold from Saul or his family, nor do we have the right to put anyone in Israel to death."5 "What do you want me to do for you?" David asked.
References for 2 Samuel 21:4
They answered the king, "As for the man who destroyed us and plotted against us so that we have been decimated and have no place anywhere in Israel,
let seven of his male descendants be given to us to be killed and exposed6 before the LORD at Gibeah of Saul--the Lord's chosen7 one." So the king said, "I will give them to you."
References for 2 Samuel 21:6
The king spared Mephibosheth8 son of Jonathan, the son of Saul, because of the oath9 before the LORD between David and Jonathan son of Saul.
References for 2 Samuel 21:7