Introduction

Healthcare workers (HCWs) were at increased risk of COVID-19 infection early in the COVID-19 pandemic (Gómez-Ochoa et al., 2021; Chou et al., 2022), but there is some evidence that this excess risk decreased as the pandemic moved forward (Cegolon et al., 2022; Cherrie et al., 2022; Fazen et al., 2023; Cherry et al., 2023a). It is unclear whether this reflected improved workplace infection prevention and control practices or vaccination, or a combination of these factors. Further, although there is little doubt that living and working through the pandemic was stressful for the population as a whole (Bu et al., 2023) and for HCWs (Li et al., 2021; Lee et al., 2023), this again seems to have reduced as the pandemic progressed, although results from longitudinal studies of HCWs are inconsistent (Umbetkulova et al., 2023). There are rather few studies directly comparing infection rates (Nguyen et al., 2020) or mental health (Cénat et al., 2021; Sasaki et al. 2021) in HCWs with those in the general population. The study reported here used administrative health records, including those for immunization and the results of polymerase chain reaction (PCR) testing, to assess whether HCWs were indeed at greater risk of COVID-19 infection than the general population in Alberta. It also considered mental health outcomes, comparing physician records of mental ill-health in HCWs and matched CRs during each wave of the pandemic, adjusting for a history of mental health (MH) conditions in the previous 3 years. This use of administrative health records allowed us to chart how the risks to HCWs evolved as the pandemic progressed.

Methods

HCWs were recruited from four Canadian provinces (Alberta, British Columbia, Ontario, and Quebec) during the early months of the pandemic and followed up through periodic questionnaires to the summer of 2022 (Cherry et al., 2023b). Participants from Alberta were asked at recruitment for consent to match their individual records to the Alberta Administrative Health Database (AHDB). In Alberta (as across Canada), healthcare is free at the point of service but for physicians to be paid for a service they must enter at least one diagnosis which is recorded in the AHDB. With individual consent, the administrative database containing such records can be made available for research. As the pandemic progressed, participants were also asked for consent to be linked to COVID-19 immunization records maintained by the provinces and for results of all PCR testing for the SARS-CoV-2 virus. With research ethics board agreement, Alberta Health attempted to match each of the consenting HCWs to five anonymized community referents (CRs) on sex, age (± 3 years), geographic location in Alberta, and number of physician claims from 1 April 2019 to 31 March 2020. Referents were alive and resident in the province on 31 March 2020, as determined by the Alberta Health population registry. Diagnostic data were extracted from inpatient care (up to 25 codes per episode), ambulatory care (up to 10 codes), and practitioner physician claims (up to three codes) for specified conditions, including mental ill-health and COVID-19. Alberta Health linked both HCWs and matched CRs to records of each PCR test (negative or positive) and vaccination (date and type) received. Data on immunizations and PCR tests were extracted from the start of the pandemic in Alberta (taken as 6 March 2020) to 31 March 2022. Data on the selected physician diagnoses were made available from 1 April 2017 to 31 March 2022, giving records for 35 months and 5 days before the start of the pandemic and for 24 months and 26 days during the pandemic.

For the analysis reported here, incident COVID-19 infection was examined using two criteria:

  1. 1.

    The first date on which a participant had received a positive PCR test; and

  2. 2.

    The first date of a physician consultation at which the specific code for COVID-19 infection (ICD-9 079.82: ICD-10 U07.1) had been recorded.

Neither definition was held to be a comprehensive or unbiased reflection of infection in the community.

Three MH conditions (anxiety disorder, stress reaction or adjustment disorder, and depressive disorder) were identified from physician records, as follows:

  • Anxiety disorders: ICD-9 300, 300.1, 300.2, 300.3, 300.8, 300.9; ICD-10 F40, F41, F42, F44, F45 F48

  • Stress and adjustment reactions: ICD-9 308, 309; ICD-10 F43

  • Depressive disorders: ICD-9 300.4 311; ICD-10 F32 F33 F34.1

Episodes were classified by the first date recorded as either before or during the pandemic. If a condition was recorded by a physician both before and after 6 March 2020, it was included in both periods.

Potential covariates of interest for infection included number and dates of immunization against COVID-19, the total number of PCR tests recorded, and the stage of the pandemic as reflected in infection waves in Alberta. These, rounded to the end of the previous month, were taken as follows: wave 1, March–June 2020 (4 months); wave 2, July 2020–February 2021 (8 months); wave 3, March–June 2021 (4 months); wave 4, July–October 2021 (4 months); wave 5 (Omicron), November 2021–March 2022 (5 months). For diagnosis of COVID-19 from results of PCR testing, the total number of tests recorded (positive or negative) was also considered. Those with no tests could not have a positive result while those with multiple tests (for whatever reason) were more likely to have an adventitious positive result, even if asymptomatic. For MH, the covariates were physician records of the same MH condition in the 35 months pre-pandemic.

Statistical methods

Odds ratios of MH diagnoses were estimated by conditional logistic regression, allowing for matching of HCWs to CRs and, in the MH analysis, for diagnoses recorded before the pandemic. To examine the evolution of risk during the pandemic, time to first COVID-19 diagnosis was examined for HCWs and CRs in a multilevel piecewise exponential model, nesting participants within matching groups (Rabe-Hesketh & Skrondal, 2022) by fitting wave-specific hazard ratios for the effect of HCWs relative to CRs. The time variable was months within each wave and the hazard was assumed constant within each wave. The analysis controlled for the number of vaccines received (as a factor variable) at the time of the event (COVID-19 diagnosis) and in the case of PCR positivity, the number of tests recorded in that month. For the MH analysis, a similar approach was adopted where individual slopes were fitted within wave for the effects of being a HCW on incidence of each MH condition within the wave, with nesting of participants within matching group. The analysis was carried out in Stata 18 (StataCorp. 2023. Stata Statistical Software: Release 18. College Station, TX: StataCorp LLC).

Results

Of 3812 Alberta HCWs who consented to join the cohort, 80% (3050/3812) agreed to be matched to the Alberta AHDB. In total, 97% (2959/3050) were identified in the database and matched to at least three community referents. The analysis reported here was based on 2959 HCWs and 14,546 CRs.

Among the HCWs, 476 (16.1%) were physicians, 2353 (79.5%) registered nurses, 58 (2.0%) licensed practical nurses, and 72 (2.4%) healthcare aides. Most were female (87.5%, 2590/2959). The median age at recruitment was 44 years.

HCWs were more likely to have a COVID-19 infection, whether identified by a PCR test (20% of HCWs had at least one positive PCR test compared to 12% of CRs) or by medical records (HCWs 32%; CRs 26%): 44% of HCWs and 33% of CRs were identified by one or other case definition (Table 1). Twenty HCWs and 32 CRs had a second positive PCR test. Repeat infection could not be confidently identified from physician diagnoses and only first cases have been considered here.

Table 1 First episode of COVID-19 and mental health conditions in healthcare workers and community referents

Examination of mental health diagnoses showed that HCWs were more likely than CRs to have a physician record of anxiety, stress/adjustment reaction, or depressive condition during the pandemic. Before the pandemic, there was no difference in the proportion of HCWs and CRs with a record of anxiety or stress/adjustment reaction but HCWs were somewhat more likely to have a record of a depressive condition. The risk estimates (odds ratios) given in Table 1 show an increased risk for HCWs of all three MH diagnoses during the pandemic, having adjusted for reports of the same condition before the pandemic.

The distribution of COVID-19 cases identified by each criterion is shown in Fig. 1, which also indicates the infection waves. Cases identified by PCR tests were predominantly in the later stages of the pandemic, while those from physician records peaked in the first wave. HCWs had more PCR tests, positive or negative, than CRs (median 3.0 vs. median 1.0, respectively) during the course of the pandemic, with the highest mean rate of tests/month in wave 2 (Table 2). In both HCWs and CRs, there was a marked increase in the proportion of tests that were positive in wave 5. Among those tested, the proportion of tests that were positive was somewhat lower for HCWs. In each wave after the first (when vaccines had not yet been introduced), HCWs had received more vaccination doses than CRs.

Fig. 1
figure 1

Distribution of cases by date and wave. A Cases from PCR test. B Cases from physician records

Table 2 First episode of COVID-19, polymerase chain reaction (PCR) tests, and vaccine shots by infection wave: healthcare workers (HCW, N=2959) and community referents (CR, N=14,546)

Table 3 gives multivariable analyses for COVID-19, computed within wave and adjusted for the number of vaccinations received and the number of PCR tests in the month of infection. Risk (hazard ratio) to HCWs, relative to CRs, of COVID-19 defined from physician records decreased with successive infection waves until the fifth (Omicron) wave. A similar pattern was evident for cases defined by PCR test, with a parallel but greater increase in wave 5. Risk decreased with vaccination where the criterion was a positive PCR test. The relation of immunization to cases in physician records showed a contrary pattern.

Table 3 Hazard of COVID-19 (healthcare workers relative to community referents) by infection wave adjusted for number of vaccines and/or number of PCR tests

The evolution of MH risk by wave is shown in Table 4. The incidence within each wave is given in the top half of the table, with anxiety being overall the most reported condition and stress/adjustment reaction the least. Wave 2, covering 8 months, has a higher absolute number of reports than the waves covering shorter periods. The odds ratio for HCWs in each wave is given in the lower half of Table 4. There was no excess of anxiety for HCWs during the first wave of the pandemic but small increased risks of conditions coded as stress, adjustment reaction, or depressive conditions were present at this point. The excess in anxiety conditions, though present in all subsequent waves, was less evident than that for depressive conditions or stress/adjustment reactions, which showed an increasing trend as the pandemic progressed, peaking at wave 4.

Table 4 Physician reports of anxiety, stress/adjustment reaction and depressive conditions by infection wave for healthcare workers (HCW) and community referents (CR)

Discussion

Matching of healthcare workers to community referents in an administrative health database allowed comparison of cases of COVID-19 and mental ill-health more readily and economically than through recruitment and retention of an active community cohort. Although the approach had limitations (discussed below), the overall excess cases of COVID-19, using two contrasting operational definitions, and of mental ill-health adjusting for pre-pandemic morbidity suggest that working during the pandemic was detrimental to the health of HCWs. The results by infection wave suggested a steady decrease in the excess risk of infection for HCWs as compared with community referents up to the onset of the Omicron wave. No corresponding decrease by wave was evident for mental ill-health, with the excess in adjustment reactions and depression peaking in the fourth wave but continuing into the fifth.

The results from this analysis are consistent with the observation (Cegolon et al., 2022; Cherry et al. 2023a) that occupational risks of infection in HCWs decreased as the pandemic progressed. An excess risk in HCWs relative to the community during the Omicron wave has been reported from Hong Kong, comparing infection rates in staff from a single hospital to those in the general population (Wong et al., 2023), but not more widely. Our earlier work has shown that while risk of work-related COVID-19 decreased after vaccination it did not disappear completely (Cherry et al., 2023a) and it seems feasible that, with a surge in infection in the population, HCWs were again at greater risk, as suggested here. The increase in risk of a diagnosis of a stress/adjustment reaction or a depressive condition from the start of the pandemic to the fourth wave (to late fall 2021) is unlikely to be due to chance. It may in part reflect a return to equanimity in the community alongside a decreasing resilience in HCWs, coping with high work demands: both factors may contribute. Previous studies have shown a deterioration in mental health in HCWs early in the pandemic (Sasaki et al., 2021). In Australia, a study following HCWs from May 2021 to June 2022 found a deterioration in MH (McGuinness et al., 2023) while one from Italy for much the same period found MH improvements (Fattori et al., 2023). A systematic review that included 18 longitudinal studies of mental health in HCWs during the pandemic concluded that 12 studies suggested deterioration over time and six improvement, attributing the ‘remarkable variation’ to use of different instruments for measuring MH (Umbetkulova et al, 2023).

Both definitions of COVID-19 infections used here had limitations. Ideally, for this analysis, all participants would have received PCR tests when symptomatic, with confirmation of infection by longitudinal serology testing. More realistically, it would have been helpful to know why PCR tests were done (for screening, suspected exposure, or symptomatic disease) and to have had results of rapid antigen tests once these became available. After the first wave, access to PCR testing through provincial testing sites was readily available in Alberta until the late summer of 2021. With the great increase in demand for tests when the highly infective Omicron variant became dominant (wave 5), PCR testing was largely limited to those positive on a rapid antigen test, resulting in the much greater positivity rate (24% overall) for both HCWs and CRs in this period. HCWs had designated testing sites at this phase which may in part explain the higher wave 5 risk (OR=2.45) by PCR result than from physician records (OR=1.31) for the same period.

The identification of COVID-19 cases from physician records also introduced difficulties of interpretation. Many, perhaps most, individuals with a positive test for COVID-19 would not have had reason to consult a family physician or visit a walk-in clinic and indeed they would have been discouraged from doing so. Many of the consultations early in the pandemic may have been from ‘worried well’ concerned that they might have been exposed to the virus rather than from symptomatic cases: the diagnostic code recorded did not carry this degree of specificity. A further complication is that patients with ongoing health concerns after the acute period of infection may have received the same diagnostic coding and such records cannot be distinguished from repeat infections. Given these considerable limitations, finding the same pattern over time by the two approaches, with decreasing excess risk from wave 1 until the increase at wave 5, is somewhat reassuring.

A strength of the dataset is that vaccination records would largely have been complete and accurate: very few would have been vaccinated out of province. The observation that vaccination was associated with an increased risk of infection when the case criterion was a physician record may reflect both greater access to physicians by those who received multiple vaccinations and an unwillingness of those not vaccinated (almost entirely CRs) to seek medical attention.

The mental health data were entirely from administrative health records. These are not comprehensive as a reflection of mental ill-health as they do not include assessment of interventions from psychologists, counsellors, or other health professionals who may give support. In Alberta, with a shortage of family physicians, HCWs might have easier physician access. A physician may be biased toward an increased readiness to record a MH diagnosis for HCWs than for other patients. Equally, HCWs may differ from other patients in their willingness to disclose mental distress to a treating physician. It is difficult to assess the extent or direction of the effects such potential differences in behaviour by physician and patient might have on the risk estimates in this paper. However, CRs were matched to HCWs on the number of physician contacts in the year before the pandemic and data from before the pandemic did not show differences in anxiety and stress/adjustment reactions. Assuming that patterns of physician use and willingness to disclose did not change differentially between HCWs and CRs, we can conclude that HCWs were more likely to have episodes of mental distress during the pandemic.

Further weaknesses lie in the response rate of HCWs to join the cohort (at best around 15% of those approached (Cherry et al., 2023b)) and the unwillingness of 20% (752 participants) to give consent to data linkage at the time of recruitment. Those who took part may not be representative of HCWs in Alberta or, indeed, of HCWs elsewhere. A further potential bias may arise in comparing employed HCWs with community members matched only on gender, age, location, and physician consultations in the previous year. Although such factors are likely to affect exposure to the SARS-CoV-2 virus and behaviour once infected, lack of information on employment (not recorded in the AHDB) in the referents may be a source of bias if employment itself (and not simply as a HCW) is a risk for COVID-19 infection.

The current study has strengths in that it uses physician records before and during the pandemic and objective testing for the SARS-CoV-2 virus. While it is appropriate to be concerned about the limitations of the data, they do provide an unusual opportunity to examine trends over time using data collected for administrative purposes. The conclusion here, as elsewhere (Chou et al. 2022; Li et al., 2021), is that HCWs were at risk early in the pandemic. These new data suggest that risk was not confined to the chaotic early months and may persist or recur with new waves of infection.

Contributions to knowledge

What does this study add to existing knowledge?

  • Although some studies have suggested excess risk of infection for healthcare workers (HCWs) decreased as the COVID-19 pandemic progressed, this is the first well-matched study to document a re-emergence of excess risk for HCWs during the Omicron wave, when the burgeoning number of cases made further demands on HCWs amid declining protection from immunization.

  • The excess risk of mental ill-health among HCWs, recorded during physician consultations, gives credence to earlier studies based largely on self-report.

What are the key implications for public health interventions, policy, or practice?

  • There is continued need for vigilance to protect HCWs from infection as new variants of COVID-19 emerge or new infectious agents spread in the community.

  • The pre-pandemic excess of depressive conditions recorded for HCWs, together with the increased excess in mental ill-health as the pandemic progressed, underlines the need for proactive and responsive provision to support the mental health of those employed within the Canadian healthcare system.