2 Samuel 7:15
13 He will build a house for my name, and I will make his dynasty permanent. 14 I will become his father and he will become my son. When he sins, I will correct him with the rod of men and with wounds inflicted by human beings. 15 But my loyal love will not be removed from him as I removed it from Saul, whom I removed from before you. 16 Your house and your kingdom will stand before me permanently; your dynasty will be permanent.’” 17 Nathan told David all these words that were revealed to him.
Psalm 89:33
31 if they break my rules and do not keep my commandments, 32 I will punish their rebellion by beating them with a club, their sin by inflicting them with bruises. 33 But I will not remove my loyal love from him nor be unfaithful to my promise. 34 I will not break my covenant or go back on what I promised. 35 Once and for all I have vowed by my own holiness, I will never deceive David.
Notes and References
"... The statement about punishment (verse 14b) is a plus in Samuel. The wording is a mixture of Psalm 89:32-33 and possibly 2 Samuel 7:19. Punishment of (only?) human proportions is perhaps to be contrasted with punishment on a divine scale; and yet David chooses divine afflictions for his people to suffer after he counts them (2 Samuel 24:13–14). and the mention of Saul in the Masoretic text (verse 15) must also be secondary. As with the previous chapters whose content has been drawn substantially from the Book of Two Houses, it is from the material peculiar to Samuel that we may deduce the special interests of its authors. Where Samuel equals Chronicles, we may be reasonably confident that we are dealing with the text inherited from the Book of Two Houses. Within the consensus view of the relationship of Samuel and Chronicles, it is arguable that the Chronicler might have deleted mention of a king in whom he was much less interested ..."
Auld, A. Graeme I & II Samuel: A Commentary (p. 423) Westminster John Knox Press, 2011