Ecclesiastes 8:14-9:10 New Revised Standard Version (NRSV)
14 There is a vanity that takes place on earth, that there are righteous people who are treated according to the conduct of the wicked, and there are wicked people who are treated according to the conduct of the righteous. I said that this also is vanity. 15 So I commend enjoyment, for there is nothing better for people under the sun than to eat, and drink, and enjoy themselves, for this will go with them in their toil through the days of life that God gives them under the sun.
16 When I applied my mind to know wisdom, and to see the business that is done on earth, how one’s eyes see sleep neither day nor night, 17 then I saw all the work of God, that no one can find out what is happening under the sun. However much they may toil in seeking, they will not find it out; even though those who are wise claim to know, they cannot find it out.
Take Life as It Comes
9 All this I laid to heart, examining it all, how the righteous and the wise and their deeds are in the hand of God; whether it is love or hate one does not know. Everything that confronts them 2 is vanity,[a] since the same fate comes to all, to the righteous and the wicked, to the good and the evil,[b] to the clean and the unclean, to those who sacrifice and those who do not sacrifice. As are the good, so are the sinners; those who swear are like those who shun an oath. 3 This is an evil in all that happens under the sun, that the same fate comes to everyone. Moreover, the hearts of all are full of evil; madness is in their hearts while they live, and after that they go to the dead. 4 But whoever is joined with all the living has hope, for a living dog is better than a dead lion. 5 The living know that they will die, but the dead know nothing; they have no more reward, and even the memory of them is lost. 6 Their love and their hate and their envy have already perished; never again will they have any share in all that happens under the sun.
7 Go, eat your bread with enjoyment, and drink your wine with a merry heart; for God has long ago approved what you do. 8 Let your garments always be white; do not let oil be lacking on your head. 9 Enjoy life with the wife whom you love, all the days of your vain life that are given you under the sun, because that is your portion in life and in your toil at which you toil under the sun. 10 Whatever your hand finds to do, do with your might; for there is no work or thought or knowledge or wisdom in Sheol, to which you are going.