John Gill's Bible Commentary Ver. 3. And keep the charge of the Lord thy God , etc.] Which may in general respect his whole walk and conversation, and his obedience to the law and will of God; and in particular his just government of Israel committed to his charge: to walk in his ways ; directed to in his word: to keep his statutes and his judgments ; his laws, ceremonial, moral, and judicial: and his testimonies ; as the above laws, which testify of his mind, and declare what he would have done and observed: as it is written in the law of Moses ; which a king of Israel was obliged to write a copy of, keep by him, and read it, and rule according to it, ( Deuteronomy 17:18-20): that thou mayest prosper in all that thou doest, and whithersoever thou turnest thyself ; to reign in righteousness, and according to the law of God, is the only way to have a prosperous and happy reign: or “that thou mayest act wisely” f22 ; the law of God furnishing out the best rules of government and maxims of policy; (see Deuteronomy 4:6,7). Ver. 4 . That the Lord may continue his word which he spake concerning me , etc.] his word of promise concerning the kingdom of David, and the succession of it, and confirm and establish it: saying, if thy children take heed to their way ; they are directed to walk in, even the way of the Lord, and not turn to the right hand or the left: to walk before me in truth : in the sincerity and integrity of their hearts, according to the word of truth, and under the influence of the spirit of truth: with all their heart, and with all their soul ; in the most cordial manner, with the strongest affection and zeal; with all eagerness and earnestness; with their whole hearts engaged in every duty performed by them: then the Lord said, there shall not fail thee a man on the throne of Israel ; one to succeed him in the throne; this, with respect to his throne, literally considered, was conditional; but, spiritually considered, was absolute, and had its fulfilment in the Messiah, whose throne is for ever; see ( Luke 1:32,33).
Matthew Henry Commentary
Verses 1-4 - David's charge to Solomon is, to keep the charge of the Lord. The authority of a dying father is much, but nothing to that of a livin God. God promised David that the Messiah should come from his descendants, and that promise was absolute; but the promise, that ther should not fail of them a man on the throne of Israel, was conditional if he walks before God in sincerity, with zeal and resolution: in orde hereunto, he must take heed to his way. (1Ki 2:5-11)
Original Hebrew ושׁמרת8104 את853 משׁמרת4931 יהוה3068 אלהיך430 ללכת1980 בדרכיו1870 לשׁמר8104 חקתיו2708 מצותיו4687 ומשׁפטיו4941 ועדותיו5715 ככתוב3789 בתורת8451 משׁה4872 למען4616 תשׂכיל7919 את853 כל3605 אשׁר834 תעשׂה6213 ואת853 כל3605 אשׁר834 תפנה6437 שׁם׃8033