Michael Fishbane, The Exegetical Imagination: On Jewish Thought and Theology (Cambridge, 1998) 19.
…Koheleth said that God created each thing for its proper time, “and even put the world (ha-‘olam) in their hearts[.]” Reading ha-olam in [Koheleth] as he-‘elem (“the youth”), Rabbi Berekhiah re-read Ecclesiastes to mean that God has even put fathers’ “love for their children (‘olelim) in their hearts.”…Others, however, preferred to interpret Koheleth as meaning that God “concealed (he-‘elim) the day of death…from His creatures[.]”
Ecclesiastes 3:11 states that God put ha-olam in the human heart. Ha-olam can be translated as “world” or “eternity.” How did the rabbis interpret this verse? The passage that Fishbane quotes from Midrash Shoher Tov revocalizes ha-olam so that it means “the youth,” “love for children,” or “concealed.”
Ecclesiastes Rabbah 3:15 offers other interpretations of ha-olam in Ecclesiastes 3:11: God put a love for the world in people’s hearts; he instilled in their hearts a fear of death so they’d get on the ball and have kids to perpetuate their name; God put the evil inclination in people’s hearts so they’d build a house, marry, and have kids, all of which may involve man’s rivalry with his neighbor; God put a love for the world and children in people’s hearts; ha-olam should be revocalized as ha-ulam (“concealed”), meaning God concealed the powerful divine name from human beings so they wouldn’t use it to hurt others; ha-olam is really he-elem (“concealment”), affirming that God has concealed from human beings his work from beginning to end.
After its statement about God putting ha-olam in the human heart, Ecclesiastes 3:11 states that man does not discover the work God has done from the beginning to the end. Translations differ as to how to tie these two ideas together. Some say God put ha-olam in the human heart, yet humans don’t know what God is doing from beginning to end. Others say he did so in order that they wouldn’t know. The Septuagint goes with the latter view.
So what does the passage mean? Peter Machinist states in the Jewish Study Bible that it means God has “given humans a sense that divine activity determines events beyond what they can see and understand, and so defines for them the limits of their reason.” Yet, Machinist continues, vv 12-13 go on to affirm that God has allowed them to enjoy their labor and the fruit thereof. In the HarperCollins Study Bible, Raymond C. Van Leeuwen says that the “quest to know all things (‘the world’) cannot be attained (1.12-13; 7.25; 8.17; 11.5)”, yet, in the face of our limits, Ecclesiastes teaches us to enjoy work and play as God’s gift.
I like the following summary of an article on the topic by Brian Gault, who discusses the revocalization of ha-olam to mean “darkness” (Eternity in the heart):
The point is that God makes the world obscure to man, a theme that runs throughout Ecclesiastes. This is the reason why man can never entirely know what God is up to. Instead of seeking comprehensive knowledge, which God makes impossible, we should simply trust him, and devote ourselves to the work He has put right in front of us.