“If a man fathers a hundred children and lives many years, so that the days of his years are many, but his soul is not satisfied with life’s good things, and he also has no burial, I say that a stillborn child is better off than he.” (ESV – Read the chapter)
While Solomon seems to promote a kind of “eat and drink for tomorrow we die,” hedonistic fatalism here, I think there’s something more afoot. As he has surveyed the world around him, he has noticed that there are many who pursue much, but whether they obtain it or not, when the pursuit becomes their god they can no longer enjoy the fruits of their labors whether larger or small.
Better in this life is to seek to find all the enjoyment we can in the things we have, working hard to see them increase, but not to the point that work becomes the end instead of the means. The best life will always be found in working hard, delighting fully in what we have (and among the chief ways to do that is to use it for the benefit of others), all with faithfulness to the Lord as our guide.