In a commentary on Ecclesiastes 9:15, Martin Luther cites the story of Themistocles, the soldier and statesman who commanded the Athenian squadron. Through his strategy, he won the Battle of Salamis, drove the Persian army from Greek soil, and saved his city. A few years later, he fell out of favor, was ostracized by his countrymen, and was banished from Athens. Thus, Luther concludes, "Themistocles did much good for his city, but received much ingratitude".
The crowd, for some reason, seems to ignore or quickly forget the good that the poor and humble man accomplishes through his wisdom. No matter. "Wisdom is [still] better than strength" even if "the poor man's wisdom is despised" (Ecc. 9:16). It's better to be a quiet, honest sage who, though forgotten, leaves much good behind, than a swaggering, strident fool who, though many applaud him, destroys much good" (Ecc. 9:18).
Accordingly, what matters in the end is not the recognition and gratitude we receive for the work we've done, but the souls of those gentle folk in whom we've sown the seeds of righteousness. Put another way: "Wisdom is justified by all her children" (Luke 7:35). Whom have you influenced through your wise and godly wisdom? A wise person sets his earthly goals on heavenly gains.