The book of Ecclesiastes has many layers. It describes the lives of people under the sun who are cut off from God. To that extent, life is vain and a grasping for the wind. In addition, when Solomon addresses the reader DIRECTLY, he is not talking about people who have turned away from God and who refuse to submit to God. It is important to see the distinction.
cut off
Captivity Reversed
The ninth chapter of the book of Daniel teaches us that Jesus Christ was killed in 31 A.D., after 3 ½ years of His public ministry, which began in 27 A.D. Since it was decreed that He should conduct His public ministry for seven years, He will complete the remaining 3 ½ years here on earth after His return. During that time, He will end the captivity of the enslaved modern descendants of the houses of Israel and Judah; deal with them in the wilderness; and ultimately bring them, together with the resurrected King David, to the Promised Land.