“What did Solomon mean when he wrote that money answers everything?”
It has been said that every virtue carried to extremes becomes a vice, which is probably true. Every good thing indulged in to excess does much the same. This is surely true of money.
The verses prior to Ecclesiastes 10:19 contrast a kingdom run by self-indulgent drunks and gluttons with a kingdom administered by wise, self-controlled princes and officials who know the proper place for leisure and pleasure in their own lives. Obviously, the citizens of the second kingdom will have a better time of it than those of the first.