In the run-up to the referendum it is appropriate that education and the church are the latest subjects to be tackled by the National Museums of Scotland in a series of little books about activities that have shaped the country. The distinctiveness of worship and schooling helped ensure that despite the incorporating Union of 1707 Scottish identity was preserved.
The story of the Kirk has been more frequently told than that of education. The twin titles Going to Church and Going to School focus attention on activities by ordinary people. Church history has been dominated by interminable controversies and schisms which affected but did not radically change what people did on a Sunday. As for education, there are a lot of myths, where there is not simple ignorance, due to the ever more pressing need for an up-to-date general history.
Donald Withrington of Aberdeen University is the scholar best placed to synthesise recent research, much of it his own. Going to School gives a taste of what could be expected from a fuller account. He is adamant that Scotland was a better educated nation from the 17th to the 19th centuries than is often thought. Even the Gaelic-speaking Highlands enjoyed widespread literacy, by both sexes.
In the wake of the Industrial Revolution much has been made of the pamphlet in 1834 describing Scotland as "a half-educated nation", but Withrington says that it is best read as a resentful Evangelical response to the growth of schools outwith the Church's control.
None the less it was the parochial basis of schooling that remained the key to near universality of provision, and with the parish being important secularly as well as for church organisation, it provided the conditions in which the 19th-century state gradually assumed control of schools from the church.
Among the key dates, Withrington singles out the Act of 1803 for particular comment. It is remembered (if at all) for giving teachers a better standard of living. But it also paved the way for the state takeover in the 1870s.
From a situation in which towns had boasted a huge variety of private-venture schools, Scotland found itself by the end of last century under close central direction. The contrast with England could not be starker. Withrington writes of the "iron rule" of inspectors whose every humourless whim teachers felt obliged to heed.
Controls only came to be relaxed once the last great changes had taken place - the advent of secondary education for all, which was an advance barely achieved by the Second World War, and the eventual decision that all teenagers should be taught in the same kind of school. Despite the sixties spurt of child-centred liberalism the legacy of top-down management remains, and the tensions are seen in today's debates about individual professionalism and national performance indicators, classroom-based curricula and the formalities of the 5-14 and Higher Still programmes.
Withrington ends with a plea that policy decisions should be informed by a better understanding of the history of school-going. Colin Maclean, author of Going to Church and a former editor of The TES Scotland, doesn't have to call for recognition of Scotland's bloodthirsty and intolerant ecclesiastical past. Half learnt and half understood, it is in the national psyche and feeds continuing prejudices.
But it is on the story of churchgoing as practised by generation upon generation of ordinary people that he aims to concentrate. Decline in the role of the church is more recent than often thought. In 1931, 38,777 children were baptised in the Church of Scotland. By 1961, the number had risen to 50, 387. In 1993, it was 14,707.
Maclean's book, unlike Withrington's, is firmly fixed in the past 150 years. He skims lightly over the first 1,000 years of Scottish Christianity, and even when controversy cannot be ignored, as with the consequences of the Disruption, he focuses on Sundays in the pew rather than disputes about faith and governance.
Why did the Victorian age produce so many hymn writers? When was burial in church grounds superseded by municipal cemeteries? These are the kinds of question Maclean answers.
Religious observance is not synonymous with churchgoing, as he observes, which is just as well in view of attendance figures. Optimistically, however, he concludes with Exodus: "The bush was not consumed."
Going to Church and Going to School. Published by the National Museums of Scotland at Pounds 4.99.