The Futility of Work
The Teacher hates the thought that everything he built must be handed to a successor who may be wise or foolish. Because labor done with wisdom and skill can still be transferred to someone who did not earn it, his heart despairs, and he asks what people really gain when their days are full of grief and even their nights cannot rest.
I18 hated all for which I had toiled under the sun, because I must leave it to the man who comes after me. 19And who knows whether that man will be wise or foolish? Yet he will take over all the labor at which I have worked skillfully under the sun. This too is futile. 20So my heart began to despair over all the labor that I had done under the sun. 21When there is a man who has labored with wisdom, knowledge, and skill, and he must give his portion to a man who has not worked for it, this too is futile and a great evil. 22For what does a man get for all the toil and striving with which he labors under the sun? 23Indeed, all his days are filled with grief, and his task is sorrowful; even at night, his mind does not rest. This too is futile.
The Teacher then recognizes that there is nothing better than to eat, drink, and enjoy one's work as something coming from God's hand. God grants wisdom, knowledge, joy, and the capacity for enjoyment to the one who pleases him, while the sinner only gathers and heaps up for another, so apart from God even labor's fruits remain vaporous.
24Nothing is better for a man than to eat and drink and enjoy his work. I have also seen that this is from the hand of God. 25For apart from Him, who can eat and who can find enjoyment? 26To the man who is pleasing in His sight, He gives wisdom and knowledge and joy, but to the sinner He assigns the task of gathering and accumulating that which he will hand over to one who pleases God. This too is futile and a pursuit of the wind.