Most patients value consistency in their relationship with the NHS: the chance to build up empathy, knowledge and trust with the same doctor over the course of a treatment or a stay in hospital.

Sudden changes to staff, or the arrival of a locum who has to catch up from medical notes, can damage that relationship, which is one of the reasons for concern at the news that Scotland's health boards are likely to spend £60 million this year on temporary doctors and consultants to fill unexpected gaps in the staffing on wards.

Precisely why this spending should be increasing, and why more locums are needed, is hard to say. Dr Neil Dewhurst of the Royal College of Physicians of Edinburgh says it is because the NHS is struggling to recruit doctors to pressured, high-stress jobs on the frontline of the service, and it is certainly true that careers in hospital medicine have become tougher and less attractive. However, a much more likely explanation is poor planning by hospital managers even though nobody would suggest that organising the supply of staff for a changeable, busy hospital is easy.

In addition, a number of other factors at work on the wards will have an effect. First, junior doctors can no longer work round the clock to fill shortages because of restrictions to their hours. The increase in the number of women doctors has also led to an increase in the number of doctors working part time and changes to immigration rules mean it is harder for doctors from outside the EU to come to the UK to work.

All of these trends have made it harder to recruit the range of staff needed for the modern hospital ward but spending more money on locums is not the answer. Most of the shortage is not at the top or the bottom of the profession – consultants and juniors – but in the middle, which means in the longer term the number of students in medicine will have to be addressed to fill this gap in years to come.

The new medical bank, which provides cover from within the NHS, is some cause for hope although it is by no means a panacea. Certainly, in highly populated areas such as Glasgow it is working well because there are likely to be doctors available, but will it work so well in less populated areas such as the Highlands? The BMA believes the beneficial effects of the system will begin to be felt next year and it is to be hoped they are right. In the meantime, Scotland's health boards are continuing to hire more and more expensive locums – to the cost of the taxpayer but more importantly to doctors and their patients.