He was usually the only person in the village who could read and write. The reason for that is the same reason that it took so long to study for those exams. All government business was conducted in Classical Chinese, called in Vietnamese chu han. You can compare this to the use of Latin in the Christian world until 1700 or so. Classical Chinese is not only completely different from modern Chinese, which in turn has nothing to do with Vietnamese language except in loan words, but it is written in ideograms.
Every different word has a different character.
We use an alphabetic script, which allows us always to spell words phonetically and at least make ourselves understood. With ideograms, you either know the correct symbol to use to express yourself, or you don't. Teachers say you have to learn 2,000 of them for the most basic communication. Since most people had to grow rice all day to stay alive, only a few could spend several thousand hours learning chu han. So there is a tradition in Viet Nam of literary training going in hand in hand with political power.