David advised Solomon to follow the spiritual and ethical rules from Deuteronomy and the covenant through Moses (see Leviticus 18:4–5; Deuteronomy 5:33; 6:4–5; 8:6; 10:12). He also mentioned the promises of the covenant with David (2 Samuel 7:12–16, 25). If Solomon followed God's rules, his heir would receive God's blessings and pass them to future generations (Psalm 89:3–4, 20, 24, 27–37).
The most important heir of David was the Messiah. The Messiah would:
show true righteousness (Isaiah 11:1–5),
gain all the benefits of the covenant (Jeremiah 33:14–16), and
create a new covenant with Israel and Judah (Jeremiah 31:31–34; Ezekiel 34:24–31; 37:24–28).
The New Testament identifies Jesus as that son of David who has come (Matthew 1:1; Romans 1:1–4). He will return to fulfill Old Testament prophecies and bless everyone (Luke 1:67–79; Galatians 3:26–29; Revelation 3:21).