A Commentary, Critical, Practical, and Explanatory on the Old and New Testaments, by Robert Jamieson, A.R. Fausset and David Brown  at sacred-texts.com
ecc 8:1(Ecc. 8:1-17)
Praise of true wisdom continued (Ecc 7:11, &c.). "Who" is to be accounted "equal to the wise man? . . . Who (like him) knoweth the interpretation" of God's providences (for example, Ecc 7:8, Ecc 7:13-14), and God's word (for example, see on Ecc 7:29; Pro 1:6)?
face to shine-- (Ecc 7:14; Act 6:15). A sunny countenance, the reflection of a tranquil conscience and serene mind. Communion with God gives it (Exo 34:29-30).
changed--into a benign expression by true wisdom (religion) (Jam 3:17). MAURER translates, "The shining (brightness) of his face is doubled," arguing that the Hebrew noun for "boldness" is never used in a bad sense (Pro 4:18). Or as Margin, "strength" (Ecc 7:19; Isa 40:31; Co2 3:18). But the adjective is used in a bad sense (Deu 28:50).
ecc 8:2the king's--Jehovah, peculiarly the king of Israel in the theocracy; Ecc 8:3-4, prove it is not the earthly king who is meant.
the oath of God--the covenant which God made with Abraham and renewed with David; Solomon remembered Psa 89:35, "I have sworn," &c. (Psa 89:36), and the penalties if David's children should forsake it (Psa 89:30-32); inflicted on Solomon himself; yet God not "utterly" forsaking him (Psa 89:33-34).
ecc 8:3hasty--rather, "Be not terror-struck so as to go out of His sight." Slavishly "terror-struck" is characteristic of the sinner's feeling toward God; he vainly tries to flee out of His sight (Psa 139:7); opposed to the "shining face" of filial confidence (Ecc 8:1; Joh 8:33-36; Rom 8:2; Jo1 4:18).
stand not--persist not.
for he doeth--God inflicts what punishment He pleases on persisting sinners (Job 23:13; Psa 115:3). True of none save God.
ecc 8:4God's very "word" is "power." So the gospel word (Rom 1:16; Heb 4:12).
who may say, &c.-- (Job 9:12; Job 33:13; Isa 45:9; Dan 4:35). Scripture does not ascribe such arbitrary power to earthly kings.
time--the neglect of the right "times" causes much of the sinful folly of the spiritually unwise (Ecc 3:1-11).
judgment--the right manner [HOLDEN]. But as God's future "judgment" is connected with the "time for every purpose" in Ecc 3:17, so it is here. The punishment of persisting sinners (Ecc 8:3) suggests it. The wise man realizes the fact, that as there is a fit "time" for every purpose, so for the "judgment." This thought cheers him in adversity (Ecc 7:14; Ecc 8:1).
ecc 8:6therefore the misery, &c.--because the foolish sinner does not think of the right "times" and the "judgment."
ecc 8:7he--the sinner, by neglecting times (for example, "the accepted time, and the day of salvation, Co2 6:2), is taken by surprise by the judgment (Ecc 3:22; Ecc 6:12; Ecc 9:12). The godly wise observe the due times of things (Ecc 3:1), and so, looking for the judgment, are not taken by surprise, though not knowing the precise "when" (Th1 5:2-4); they "know the time" to all saving purposes (Rom 13:11).
ecc 8:8spirit--"breath of life" (Ecc 3:19), as the words following require. Not "wind," as WEISS thinks (Pro 30:4). This verse naturally follows the subject of "times" and "judgment" (Ecc 8:6-7).
discharge--alluding to the liability to military service of all above twenty years old (Num 1:3), yet many were exempted (Deu 20:5-8). But in that war (death) there is no exemption.
those . . . given to--literally, the master of it. Wickedness can get money for the sinner, but cannot deliver him from the death, temporal and eternal, which is its penalty (Isa 28:15, Isa 28:18).
ecc 8:9his own hurt--The tyrannical ruler "hurts" not merely his subjects, but himself; so Rehoboam (1Ki. 12:1-33); but the "time" of "hurt" chiefly refers to eternal ruin, incurred by "wickedness," at "the day of death" (Ecc 8:8), and the "time" of "judgment" (Ecc 8:6; Pro 8:36).
ecc 8:10the wicked--namely, rulers (Ecc 8:9).
buried--with funeral pomp by man, though little meriting it (Jer 22:19); but this only formed the more awful contrast to their death, temporal and eternal, inflicted by God (Luk 16:22-23).
come and gone from the place of the holy--went to and came from the place of judicature, where they sat as God's representatives (Psa 82:1-6), with pomp [HOLDEN]. WEISS translates, "Buried and gone (utterly), even from the holy place they departed." As Joab, by Solomon's command, was sent to the grave from the "holy place" in the temple, which was not a sanctuary to murderers (Exo 21:14; Kg1 2:28, Kg1 2:31). The use of the very word "bury" there makes this view likely; still "who had come and gone" may be retained. Joab came to the altar, but had to go from it; so the "wicked rulers" (Ecc 8:9) (including high priests) came to, and went from, the temple, on occasions of solemn worship, but did not thereby escape their doom.
forgotten-- (Pro 10:7).
ecc 8:11The reason why the wicked persevere in sin: God's delay in judgment (Mat 24:48-51; Pe2 3:8-9). "They see not the smoke of the pit, therefore they dread not the fire" [SOUTH], (Psa 55:19). Joab's escape from the punishment of his murder of Abner, so far from "leading him to repentance," as it ought (Rom 2:4), led him to the additional murder of Amasa.
ecc 8:12He says this, lest the sinner should abuse the statement (Ecc 7:15), "A wicked man prolongeth his life."
before him--literally, "at His presence"; reverently serve Him, realizing His continual presence.
ecc 8:13neither shall he prolong--not a contradiction to Ecc 8:12. The "prolonging" of his days there is only seeming, not real. Taking into account his eternal existence, his present days, however seemingly long, are really short. God's delay (Ecc 8:11) exists only in man's short-sighted view. It gives scope to the sinner to repent, or else to fill up his full measure of guilt; and so, in either case, tends to the final vindication of God's ways. It gives exercise to the faith, patience, and perseverance of saints.
shadow-- (Ecc 6:12; Job 8:9).
ecc 8:14An objection is here started (entertained by Solomon in his apostasy), as in Ecc 3:16; Ecc 7:15, to the truth of retributive justice, from the fact of the just and the wicked not now receiving always according to their respective deserts; a cavil, which would seem the more weighty to men living under the Mosaic covenant of temporal sanctions. The objector adds, as Solomon had said, that the worldling's pursuits are "vanity" (Ecc 8:10), "I say (not 'said') this also is vanity. Then I commend mirth," &c. [HOLDEN]. Ecc 8:14-15 may, however, be explained as teaching a cheerful, thankful use of God's gifts "under the sun," that is, not making them the chief good, as sensualists do, which Ecc 2:2; Ecc 7:2, forbid; but in "the fear of God," as Ecc 3:12; Ecc 5:18; Ecc 7:18; Ecc 9:7, opposed to the abstinence of the self-righteous ascetic (Ecc 7:16), and of the miser (Ecc 5:17).
ecc 8:15no better thing, &c.--namely, for the "just" man, whose chief good is religion, not for the worldly.
abide--Hebrew, "adhere"; not for ever, but it is the only sure good to be enjoyed from earthly labors (equivalent to "of his labor the days of his life"). Still, the language resembles the skeptical precept (Co1 15:32), introduced only to be refuted; and "abide" is too strong language, perhaps, for a religious man to apply to "eating" and "mirth."
ecc 8:16Reply to Ecc 8:14-15. When I applied myself to observe man's toils after happiness (some of them so incessant as not to allow sufficient time for "sleep"), then (Ecc 8:17, the apodosis) I saw that man cannot find out (the reason of) God's inscrutable dealings with the "just" and with the "wicked" here (Ecc 8:14; Ecc 3:11; Job 5:9; Rom 11:33); his duty is to acquiesce in them as good, because they are God's, though he sees not all the reasons for them (Psa 73:16). It is enough to know "the righteous are in God's hand" (Ecc 9:1). "Over wise" (Ecc 7:16); that is, Speculations above what is written are vain.