Correlation between admission hyperglycemia and postoperative pneumonia after hip fracture surgery: A propensity score-matched study Authors: Yuanchao Luo, Xiaomin Ni, Wei Yao, Wei Wang, Yuhao Li, Qiaomei Lv, Wenbo Ding, Wanyun Tang Published: 2024 ABSTRACT AbstractThe association between admission hyperglycemia and postoperative pneumonia is unclear in hip fracture patients. We investigated the relationship between admission hyperglycemia and postoperative pneumonia after hip fracture surgery. This retrospective study analyzed data from 1,267 geriatric patients admitted for hip fractures. Patients were categorized into normoglycemic (< 6.10 mmol/L) and hyperglycemic (≥ 6.10 mmol/L) groups based on admission blood glucose levels. Multivariable logistic regression and propensity score matching (PSM) were used to control for potential confounding variables and estimate adjusted odds ratios and 95% confidence intervals for postoperative pneumonia (POP). We also examined the dose-dependent link between admission blood glucose and the likelihood of developing POP. Further analyses evaluated whether admission hyperglycemia has differing impacts on POP outcomes among hip fracture patients without diabetes (NDM) versus those with diabetes (DM). Additionally, subgroup analyses were conducted to assess the influence of other factors on the relationship between admission blood glucose and POP occurrence. Patients with admission hyperglycemia had significantly higher rates of POP compared to normoglycemic patients, both before (13.2% vs. 4.8%) and after (10.1% vs. 5.8%) PSM. Admission hyperglycemia is an independent risk factor of POP (OR = 2.64, 95% CI: 1.42–4.92, p = 0.002). The association persisted after PSM(OR = 2.90, 95% CI: 1.35–3.86, p = 0.016). Additionally, higher blood glucose levels correlated with a greater likelihood of developing POP. A dose–response relationship was observed between blood glucose levels and the risk of POP. Non-diabetic group patients with hyperglycemia were at higher risk of POP than diabetic group patients with hyperglycemia. Finally, the relationship between hyperglycemia and increased POP risk is modulated and influenced by the ASA classification of the patient. Admission hyperglycemia is an independent risk factor for POP after hip fracture surgery in the elderly. There is a dose–response relationship between admission blood glucose and the occurrence of POP, which is more significant in non-diabetic patients than diabetic patients.Keywords: Hip fracture, POP, Hyperglycemia, Risk factor, GeriatricSubject terms: Endocrinology, Risk factors Introduction Hip fractures pose a major health threat to the elderly, significantly impacting mobility, independence, and well-being1–3. With rising fracture incidence due to increased life expectancy and osteoporosis, the burden on healthcare systems grows4–6. Currently, early surgical intervention is standard practice7,8. However, surgery risks serious complications like postoperative pneumonia (POP), which markedly increases hospitalization, cost, and mortality9,10. In addition, several studies have shown that the incidence of POP after hip fracture in the elderly is high, ranging from 4.9% to 15%11–15. The prevention, diagnosis, and management of POP in elderly hip fracture patients are therefore clinically critical. There are several risk factors for POP after hip fracture surgery, including advanced age, malnutrition, and comorbidities12,16,17. Many studies have confirmed that diabetes mellitus is an independent risk factor for postoperative pneumonia18,19. However, the relationship between admission hyperglycemia and the risk of developing POP after hip fracture remains unclear. Stress hyperglycemia is common and likely to be associated with some complications20,21. Some evidence suggests that hyperglycemia may contribute to POP. While the exact mechanisms are still under investigation, several hypotheses attempt to explain this association. Hyperglycemia is thought to Impair the immune system’s ability to fight infection, making patients more susceptible to developing pneumonia after surgery22,23. Exacerbate existing inflammation, further compromising the body’s natural healing processes and increasing the risk of complications, including POP24,25. Induce oxidative stress, a cellular imbalance associated with tissue damage that may contribute to lung dysfunction, which can pave the way for pneumonia26. Sodium-glucose cotransporter 2 inhibitors (SGLT2is), with their pleiotropic and anti-inflammatory properties, may reduce the risk of pneumonia27,28. Therefore, this study aimed to investigate the correlation between admission hyperglycemia and postoperative pneumonia in patients undergoing hip fracture surgery. Further analyses evaluated whether admission hyperglycemia had a different impact on POP outcomes in hip fracture patients without diabetes (NDM) versus those with diabetes (DM). Methods Data sources We performed a retrospective review of de-identified data extracted from electronic health records (EHRs) of patients who underwent surgical treatment for hip fractures at our medical facility from November 2011 to October 2023. Information regarding patient demographics, medical history, surgical variables, laboratory findings, and postoperative complications was gathered from the hospital’s electronic database. It should be noted that “bedridden time” specifically refers to the period from hospital admission to surgery when the patient is confined to bed. This study received approval from the Institutional Review Board (IRB) of our institution (IRB No. DDZX-202401103). Given the observational nature of our investigation, informed consent requirements were waived in accordance with national regulations and institutional policies. Exclusion and inclusion criteria Our study cohort comprised geriatric individuals with confirmed hip fractures diagnosed via X-ray or CT imaging followed by surgical confirmation. Exclusion criteria included: (1) Lack of surgical intervention; (2) Age below 60 years; (3) Pathological, old, multiple, or open fractures; (4) Severe infections or malignancies; (5) Severe cardiac, hepatic, or renal dysfunction; and (6) Incomplete data. A total of 892 patients were excluded based on these criteria, resulting in a retrospective cohort study involving 1,267 patients. Exposure and outcome The primary focus of our investigation was the presence of hyperglycemia upon admission to the hospital, which was defined as a blood glucose level equal to or exceeding 6.10 mmol/L. Blood samples were collected from hip fracture patients within 24 h of hospital admission to ascertain baseline hyperglycemia. Normal blood glucose levels were established within the range of 4.00–6.10 mmol/L. In our analysis, admission blood glucose levels were stratified into four quartile groups, namely Q1 (< 5.3 mmol/L), Q2 (5.30–6.00 mmol/L), Q3 (6.00–6.95 mmol/L), and Q4 (≥ 6.95 mmol/L), to explore any potential dose–response relationship with postoperative pain (POP) subsequent to hip fracture surgery among geriatric patients. The primary outcome measure was the incidence of postoperative pneumonia (POP) following hip fracture surgery. Patients were categorized as having POP if they exhibited new infiltrates on postoperative chest X-rays, provided they had no evidence of pneumonia prior to surgery. One or more of the following criteria needs to be met29,30: (1) Presence of new onset or exacerbation of respiratory symptoms, such as cough and production of purulent sputum. (2) Abnormal body temperature, including fever (> 38°C) or hypothermia (< 36.0°C). (3) Observation of lung abnormalities during physical examination, such as consolidations or crackles. (4) Abnormal white blood cell count indicating either leukocytosis (> 10 × 109/L) or leukopenia (< 4 × 109/L). (5) Detection of relevant pathogens from sputum or blood cultures. Statistical analysis In the descriptive analysis, categorical variables were presented as percentages (%) and compared between groups using chi-square tests. Continuous variables were expressed as mean ± standard deviation (SD) and compared between the two groups using independent sample t-tests. For comparisons among multiple groups, the mean values of continuous variables were analyzed using one-way ANOVA. The relationship between blood glucose levels and the occurrence of postoperative pneumonia (POP) was investigated using logistic regression models. Initial univariate logistic regression analyses were conducted to adjust for potential confounding factors with p-values ≥ 0.05. Variables with p-values < 0.05 were subsequently included in multivariate logistic regression models31. The area under the receiver operating characteristic (ROC) curve (AUC) was calculated to evaluate the predictive ability of blood glucose levels for POP. Additionally, a restricted cubic spline plot was generated to flexibly depict the association between continuous glucose levels and the risk of POP using 4 knots32. The association between glucose levels and POP risk was further assessed by plotting observed rates and predicted probabilities against glucose levels. To minimize potential confounding effects of covariates, we utilized PSM employing the nearest neighbor algorithm in a 1:1 ratio to achieve balanced covariates between the groups33. A caliper width of 0.25 standard deviations (SD) was applied to match group characteristics, as evaluated by standardized mean differences (SMDs). Subsequently, a subgroup analysis was conducted within the PSM cohort to assess the diagnostic utility of admission blood glucose. Stratification based on all covariates was performed within the PSM cohort, and univariate logistic regression analysis was carried out to explore the association between hyperglycemia and POP. Odds ratios (ORs) and corresponding 95% confidence intervals (CIs) were calculated to quantify the strength of the association. Further analyses aimed to assess whether admission hyperglycemia had divergent effects on postoperative pneumonia (POP) outcomes among hip fracture patients without diabetes (NDM) compared to those with diabetes (DM). Additionally, subgroup analyses were performed to explore the influence of other factors on the association between admission blood glucose levels and the occurrence of POP. All statistical analyses were carried out using SPSS version 26 (IBM Corp., Armonk, NY, USA) and R software version 4.0.3 (R Foundation for Statistical Computing, Vienna, Austria). Results Baseline characteristics After applying the exclusion criteria, 1267 patients were included in the final analysis (eFigure 1). Patients with POP showed higher prevalence of COPD, cardiovascular disease, stroke, and higher ASA classification compared to those without POP (Table 1). The supplementary eTable 2 demonstrates that higher admission blood glucose quartiles are associated with older age, increased comorbidities, higher ASA scores. Table 1Baseline characteristics of non-POP and POP in patients with hip fracture.VariablesNon-POP(n = 1150)POP(n = 117)pDemographic Male gender (n, %)455 (39.6)82.52 (8.05) < 0.001 Age, × year74.13 (8.53)75.00 (13.00) < 0.001 Smoking (n, %)194 (16.9)21(17.9)0.767 Hypertension (n, %)569 (49.5)68 (58.1)0.075 Diabetes (n, %)259 (22.5)34 (29.1)0.110 COPD (n, %)100 (8.7)48 (41.0) < 0.001 Cardiovascular disease (n, %)340 (29.6)51 (43.6)0.002 Stroke (n, %)281 (24.4)50 (42.7) < 0.001Fracture type Femoral neck fracture (n, %)632 (55.0)45 (38.5) < 0.001 Intertrochanteric fracture (n, %)447 (38.9)69 (59.0) Subtrochanteric fracture (n, %)71 (6.1)3 (2.5)ASA III-V (n, %)527 (45.8)93 (79.5) < 0.001 I-II (n, %)623 (55.2)24 (20.5)Operation Intraoperative time, × hour1.65 (0.80)1.71 (0.73)0.447 Intraoperative blood loss, × ml173.41 (154.28)186.26 (132.98)0.385 Bedridden time, × day5.69 (3.87)7.85 (4.93) < 0.001Laboratory findings ALB, × g/dL38.20 (4.44)34.92 (5.41) < 0.001 HGB level, × g/L120.43 (20.13)113.69 (22.38)0.002 RBC level, × 109/L3.95 (0.66)3.71 (0.77)0.002 WBC count, × 109/L8.76 (2.79)11.80 (3.50) < 0.001 D-Dimer, × mg/L4.86 (4.96)6.51 (5.83) < 0.001 Cr, × umol/L72.68 (65.75)69.40 (50.33)0.515 Glucose, × umol/L6.81 (2.63)8.23 (3.45) < 0.001COPD, Chronic Obstructive Pulmonary Disease; ASA: the American Society of Anesthesiologists Physical Status Classification System; ALB, albumin; HGB, hemoglobin; RBC, red blood cell; WBC, White blood cell; Cr, Creatinine. Baseline characteristics of non-POP and POP in patients with hip fracture. COPD, Chronic Obstructive Pulmonary Disease; ASA: the American Society of Anesthesiologists Physical Status Classification System; ALB, albumin; HGB, hemoglobin; RBC, red blood cell; WBC, White blood cell; Cr, Creatinine. Multivariate analysis To explore the association between 32 factors and POP, both univariate and multivariate analyses were conducted (Table 2). After controlling for potential confounding variables, four factors emerged as independent predictors of POP: age, intracerebral hemorrhage, ASA classification, and blood glucose levels. These factors retained their significance even after adjusting for other variables. Table 2Univariate and multivariate analysis for POP after hip fracture surgery in geriatric patients.VariablesUnivariateMultivariateOR95%CIP-valueOR95%CIP-valueMale gender2.0121.441–3.118 < 0.0012.1791.349–3.5200.001Age1.1051.079–1.131 < 0.0011.0801.078–1.113 < 0.001Smoking1.0780.656–1.7710.767NANANAHypertension1.4170.964–2.0830.076NANANADiabetes1.4090.924–2.1500.111NANANACOPD7.3044.791–1.135 < 0.0013.6622.178–6.156 < 0.001Cardiovascular disease1.8411.250–2.7100.0021.0360.634–1.6850.887Stroke2.3081.562–3.409 < 0.0011.6711.030–2.7090.037Fracture type0.7160.530–0.9660.0291.4650.950–2.2590.084ASA4.5812.882–7.282 < 0.0012.3031.345–3.9410.002Intraoperative time1.0900.873–1.3630.446NANANAIntraoperative blood loss1.0010.999–1.0020.386NANANABedridden time1.0981.057–1.142 < 0.0011.0511.004–1.1010.034ALB0.8650.830–0.900 < 0.0010.9280.876–0.9840.012HGB level0.9810.969–0.9930.0020.9940.966–1.0220.674RBC level0.5940.450–0.785 < 0.0010.9980.421–2.3690.997WBC count1.3151.239–1.396 < 0.0011.3111.215–1.415 < 0.001D-Dimer1.0591.026–1.063 < 0.0011.0330.990–1.0770.132Cr0.9990.995–1.0030.602NANANAGlucose1.1581.100–1.219 < 0.0011.0861.012–1.1650.022COPD, Chronic Obstructive Pulmonary Disease; ASA: the American Society of Anesthesiologists Physical Status Classification System; ALB, albumin; HGB, hemoglobin; RBC, red blood cell; WBC, White blood cell; Cr, Creatinine; CI, confidence interval; OR, odds ratio. Univariate and multivariate analysis for POP after hip fracture surgery in geriatric patients. COPD, Chronic Obstructive Pulmonary Disease; ASA: the American Society of Anesthesiologists Physical Status Classification System; ALB, albumin; HGB, hemoglobin; RBC, red blood cell; WBC, White blood cell; Cr, Creatinine; CI, confidence interval; OR, odds ratio. Propensity score matching The baseline characteristics of patients stratified into < 6.1 mmol/L and ≥ 6.1 mmol/L groups before and after 1:1 propensity score matching (PSM) are presented in Table 3. PSM achieved a good balance between glucose < 6.1 mmol/L and ≥ 6.1 mmol/L groups, with standardized mean differences < 0.1 for most variables. By quartiles (Q1,Q2, Q3, and Q4) based on glucose levels, PSM also achieved a good balance (eTable 2, 3, and 4). Table 3Baseline characteristics and SMD before and after PSM by admission blood glucose (≥ 6.10 mmol/L vs. < 6.10 mmol/L).VariablesBefore PSMAfter PSM < 6.10 mmol/L(n = 602) ≥ 6.10 mmol/L(n = 665)SMD < 6.10 mmol/L(n = 378) ≥ 6.10 mmol/L(n = 378)SMDDemographic Male gender (n, %)270 (44.9)253 (38.0)0.138158 (41.8)161 (42.6)0.016 Age, × year72.68 (9.83)76.92 (9.14)0.44776.00 (9.83)76.92 (9.14)0.045 Smoking (n, %)115 (19.1)100 (12.0)0.10864 (16.9)67 (17.7)0.021 Hypertension (n, %)242 (40.2)395 (59.4)0.391202 (53.4)194 (51.3)0.042 Diabetes (n, %)47 (7.8)246 (37.0)0.74746 (12.2)51 (13.5)0.040 COPD (n, %)55 (9.1)93 (14.0)0.15240 (10.6)41 (10.8)0.009 Cardiovascular disease (n, %)161 (26.7)230 (34.6)0.171123 (32.5)116 (30.7)0.040 Stroke (n, %)132 (21.9)199 (29.9)0183105 (27.8)103 (27.2)0.012Fracture type Femoral neck fracture (n, %)370 (61.5)307 (46.2)0.272199 (52.6)193 (51.1)0.021 Intertrochanteric fracture (n, %)200 (33.2)316 (47.5)153 (40.5)160 (42.3) Subtrochanteric fracture (n, %)32 (5.3)42 (6.3)26 (6.9)25 (6.6)ASA III-V (n, %)250 (41.5)370 (55.6)0.285193 (51.1)188 (49.7)0.026 I-II (n, %)352 (58.5)295 (44.4)185 (48.9)190 (50.3)Operation Intraoperative time, × hour1.60 (0.74)1.71 (0.83)0.1461.66 (0.76)1.66 (0.74)0.009 Intraoperative blood loss, × ml162.80 (152.87)185.27 (151.37)0.148170.32 (154.93)173.89 (132.97)0.025 Bedridden time, × day5.37 (3.35)6.36 (4.51)0.2515.68 (3.47)5.76 (4.24)0.020Laboratory findings ALB, × g/dL38.32 (4.65)37.52 (4.60)0.17337.53 (4.70)37.51 (4.96)0.003 HGB level, × g/L121.50 (20.52)118.28 (20.25)0.158118.96 (20.61)117.97 (19.95)0.049 RBC level, × 109/L3.99 (0.66)3.87 (0.67)0.1713.89 (0.66)3.85 (0.66)0.065 WBC count, × 109/L8.36 (2.67)9.65 (3.14)0.4458.90 (2.68)8.89 (2.59)0.004 D-Dimer, × mg/L4.29 (4.51)5.48 (5.47)0.2394.75 (4.75)4.73 (4.71)0.004 Cr, × umol/L71.15 (63.69)73.49 (65.19)0.03673.54 (63.75)71.72 (61.21)0.028SMD, standardized mean difference, Used to evaluate the balance before and after PSM, ≥ 0.5 indicates imbalance; PSM: propensity score matching; COPD, Chronic Obstructive Pulmonary Disease; ASA: the American Society of Anesthesiologists Physical Status Classification System; ALB, albumin; HGB, hemoglobin; RBC, red blood cell; WBC, White blood cell; Cr, Creatinine. Baseline characteristics and SMD before and after PSM by admission blood glucose (≥ 6.10 mmol/L vs. < 6.10 mmol/L). SMD, standardized mean difference, Used to evaluate the balance before and after PSM, ≥ 0.5 indicates imbalance; PSM: propensity score matching; COPD, Chronic Obstructive Pulmonary Disease; ASA: the American Society of Anesthesiologists Physical Status Classification System; ALB, albumin; HGB, hemoglobin; RBC, red blood cell; WBC, White blood cell; Cr, Creatinine. Correlation between admission hyperglycemia and POP Glucose levels were significantly higher in readmission patients than non-readmission patients, both before(8.23 mmol/L vs. 6.81 mmol/L, p < 0.001) and after matching (7.34 mmol/L vs. 6.36 mmol/L, p = 0.003) (Fig. 1A and C). Patients with hyperglycemia had higher POP rates than normoglycemic patients before (13.2% vs 4.8%, p < 0.001) and after PSM (10.1% vs 5.8%, p = 0.031) (Fig. 1B, D and Table 4). Patients with hyperglycemia had a significantly higher risk of POP compared to normoglycemic patients (unadjusted OR 3.56, 95% CI 2.09–6.06, p < 0.001). This association remained significant after multivariable regression adjusting for confounders (adjusted OR 2.64, 95% CI 1.42–4.92, p = 0.002) and using PSM to minimize bias (PSM-adjusted OR 2.90, 95% CI 1.35–3.86, p = 0.016). Analyzing admission glucose as a continuous variable further supported the findings. Each 1 mmol/L increase in admission glucose was associated with a 16% unadjusted and 9% adjusted increase in the odds of POP (Table 5). Relationship between admission blood glucose level and POP before and after PSM. (A) Mean and standard deviation of admission blood glucose levels between the POP group and non-POP group before PSM. (B) The POP rates between the normal admission blood glucose group and hyperglycemia group before PSM. (C) The POP rates among the 4 quartile groups before PSM (Q1, Q2, Q3, Q4). (D) Mean and standard deviation of admission blood glucose levels between the POP group and non-POP group before PSM. (E) The POP rates between the normal admission blood glucose group and the hyperglycemia group before PSM. (F) The POP rates among the 4 quartile groups after PSM. Table 4The incidence of POP before and after PSM based on admission blood glucose levels (≥ 6.10 mmol/L vs. < 6.10 mmol/L).TypeNo. (%)Before PSM*p-valueNo. (%)After PSM*p-valueClinical cutoffsWithout POPPOPClinical cutoffsWithout POPPOPCutoff value < 6.10 (n = 602) (n = 1014)573 (95.2%)29 (4.8%) < 0.001 < 6.10 (n = 349) (n = 1014)351 (94.2%)27 (5.8%)0.031 ≥ 6.10 (n = 665)577 (86.8%)88 (13.2%) ≥ 6.10 (n = 349)340 (89.9%)38 (10.1%)p-value is from the Chi-Squared Test to indicate significant differentiation (P < 0.05 means significant differentiation). The incidence of POP before and after PSM based on admission blood glucose levels (≥ 6.10 mmol/L vs. < 6.10 mmol/L). p-value is from the Chi-Squared Test to indicate significant differentiation (P < 0.05 means significant differentiation). Table 5The unadjusted and risk-adjusted OR of POP by different admission blood glucose levels.TypeGlucose levels (mmol/L)Unadjusted ORP* trend 1Multivariable Regression adjusted ORP trend 2PSM adjusted ORP trend 3ContinuousPer 11.16 (1.10–1.22) < 0.0011.09(1.01–1.17)0.022NANACutoff value < 6.101 [Reference] < 0.0011 [Reference]0.0021 [Reference]0.016 ≥ 6.103.56 (2.09–6.06)2.64 (1.42–4.92)2.90 (1.35–3.86)QuartileQ1(0.00–5.30)1 [Reference]NA1 [Reference]NA1 [Reference]NAQ2(5.30–6.00)1.62 (0.78–3.37)0.1981.38 (0.63–3.05)0.4201.39 (0.62–3.07)0.423Q3(6.00–6.95)3.21 (1.64–6.31)0.0012.14 (1.02–4.58)0.0492.61 (1.12–6.08)0.026Q4(> 6.95)4.93 (2.57–9.46) < 0.0012.23 (1.07–4.75)0.0333.06 (1.23–7.59)0.016CI, confidence interval; OR, odds ratio; PSM, propensity scores matching. The unadjusted and risk-adjusted OR of POP by different admission blood glucose levels. CI, confidence interval; OR, odds ratio; PSM, propensity scores matching. Admission glucose levels were associated with an increased risk of POP. Compared to the lowest glucose quartile (Q1), patients in higher quartiles (Q3-Q4) demonstrated increased risk after adjusting for confounders (Q3: adjusted OR 2.14, 95% CI 1.02–4.58, p = 0.049; Q4: adjusted OR 2.23, 95% CI 1.07–4.75, p = 0.033). This association remained significant after PSM(Q3: PSM-adjusted OR 2.61, 95% CI 1.12–6.08, p = 0.026; Q4: PSM-adjusted OR 3.06, 95% CI 1.23–7.59, p = 0.016). There is no significant difference in statistics between Q1 and Q2(Q2: adjusted OR 1.62, 95% CI 0.78–3.37, p = 0.198; PSM-adjusted OR 1.39, 95% CI 0.62–3.07, p = 0.423) (Table 5). Additionally, admission blood glucose had a good predictive value for POP risk, as indicated by the ROC curve both before PSM (AUC 0.766, 95%CI: 0.727–0.805) and after PSM (AUC 0.734, 95%CI: 0.692–0.776) (Fig. 2A and B). The ROC of admission blood glucose level predicting POP before (A) and after (B) PSM. Dose–effect relationship and dose–response relationship POP rates increased with increasing admission blood glucose quartile, both before PSM(Q1 3.7%, Q2 6.0%, Q3 11.2%, Q4 16.2%) (Fig. 1C) and after PSM (Q1 4.1%, Q2 5.6%, Q3 9.1%, Q4 16.7%) (Fig. 1F). A dose–effect and dose–response relationship was observed between admission glucose and POP before and after PSM (Figs. 3 and 4). The OR curve showed a significant positive association between blood glucose and OR. When glucose reaches 6.10mmol/L, the OR is close to 1 (Figs. 3A and 4A). The OR increased by 1.09 (95% CI 1.01–1.17) for every 1 mmol/L increase in blood glucose (Table 5). The prediction and observation probabilities of POP increase with the increase of admission blood glucose levels, and there is good consistency between the predicted and observed values (Figs. 3B and 4B). A dose–response correlation between admission blood glucose level and POP in patients with hip fracture before PSM. (A) Adjusted odds ratios (ORs) and 95% confidence intervals (CIs) are shown for every 2 mmol/L deviation away from the reference value (6.1 mmol/L). (B) Predicted probabilities and the observed rate of POP. A dose–response correlation between admission blood glucose level and POP in patients with hip fracture after PSM. (A) Adjusted odds ratios (ORs) and 95% confidence intervals (CIs) are shown for every 2 mmol/L deviation away from the reference value (6.1 mmol/L). (B) Predicted probabilities and the observed rate of POP. In summary, these data demonstrate admission hyperglycemia is an independent risk factor for POP with a dose–effect and dose–response relationship, indicating that the higher the admission blood glucose level, the greater the risk of POP. Influence of diabetes status on results The effect of blood glucose for POP was inconsistent between the NDM group and DM group. For NDM patients, glucose levels were significantly higher in the POP group compared to the non-POP group (7.14 mmol/L vs 6.06 mmol/L, p < 0.001) (Fig. 5A). Additionally, the incidence of POP was significantly higher in the hyperglycemia group vs the normoglycemia group (4.7% vs 13.4%, p < 0.01) (Fig. 5B). However, for NDM patients, glucose levels were no significantly higher in the POP group compared to the non-POP group (10.79 mmol/L vs. 9.43 mmol/L, p = 0.113) (Fig. 5C). Similarly, the incidence of POP was not significantly higher in the hyperglycemia group vs the normoglycemia group (13.0% vs 6.4%, p = 0.199) (Fig. 5D). Relationship between admission blood glucose level and POP between the NDM patients and DM patients. (A) Mean and standard deviation of admission blood glucose levels between the POP group and non-POP group for the NDM patients. (B) The POP rates between the normal admission blood glucose group and the hyperglycemia group for the NDM patients. (C) Mean and standard deviation of admission blood glucose levels between the POP group and non-POP group for the DM patients. (D) The POP rates between the normal admission blood glucose group and the hyperglycemia group for the DM patients. (E) Adjusted odds ratios (ORs) and 95% confidence intervals (CIs) of POP are shown for every 2 mmol/L deviations away from the reference value (non-diabetic patients: 5.81 mmol/L vs. diabetic patients: 8.70 mmol/L). In Fig. 5E, the adjusted odds ratios (OR) for POP across admission blood glucose levels in NDM and DM patients are shown. Compared with NDM, the OR curve is relatively flat, for diabetic patients, and ORs became close to 1 when glucose reached 8.70 mmol/L (eFigure 2A and 2B). For non-diabetics, the OR curve of the NDM patients is steeper. When glucose reaches only 5.81mmol/L, the OR is close to 1. Interaction analysis To explore potential interactions between admission hyperglycemia and other variables, this study analyzed various factors, as shown in Fig. 6A, B, and C. In interaction analysis, we found a significant interaction between ASA classification and hyperglycemia, suggesting ASA classification may influence the effect of hyperglycemia on POP risk. Admission blood glucose level was significantly correlated with postoperative pneumonia in patients with higher ASA classification (OR = 2.98, 95%CI:1.48–6.00), but not in those with lower ASA grades (OR = 0.67, 95%CI: 0.25–1.80) (p = 0.016). The ASA classification itself reflects a patient’s overall health status and surgical risk. Patients with higher ASA grades are more likely to have concurrent diabetes and preoperative hyperglycemia. These underlying conditions may amplify the risk effect of hyperglycemia. According to the literature, false positives may occur when analyzing multiple subgroups. Therefore, the observed interaction between hyperglycemia and ASA classification needs further investigation. In addition, no statistically significant interaction was observed between hyperglycemia and the other variables examined in their influence on POP. Subgroup analysis of association admission hyperglycemia and POP after PSM. (A) Subgroup analysis of variables related to demographics and comorbidities; (B) Subgroup analysis of variables related to laboratory findings; (C) Subgroup analysis of variables related to operation. Discussion In this retrospective study of 1,267 elderly patients undergoing hip fracture surgery, we found that admission hyperglycemia was an independent risk factor for POP. Patients with admission hyperglycemia had a 2.9-fold increased risk of developing POP compared with normoglycemic patients, even after adjustment for potential confounders. In addition, higher admission glucose levels strongly correlated with higher POP incidence in a dose-dependent manner. Our findings are consistent with previous studies demonstrating hyperglycemia as a predictor of POP after surgery. For example, Buehler et al. investigated 2451 patients with general surgery and found patients with hyperglycemia had considerably higher total hospitalization costs (20,273 vs 72,675 USD, P < 0 0.001) and greater rates of POP (1.5% vs 9.6%, P < 0 0.001) compared to the control group34. Shanks et al. conducted a study of 3150 patients and confirmed hyperglycemia is independently associated with (POP) after non-cardiac surgery35. The inclusion of 600 individuals in a propensity-matched study led by Tang et al. reported that admission hyperglycemia in elderly hip fracture patients was a significant predictor of POP (OR = 2.090, 95% CI: 1.135–3.846, p = 0.016)36. In a prospective study, Chang et al. identified hyperglycemia (> 200 mg/dL) as a risk factor incidence of POP hip fracture patients (OR = 24.75, p < 0.001)37. A retrospective cohort study by Jensen found that poor perioperative glycemic control was an independent predictor of respiratory infections38. A population-based case–control study including 34,239 patients found that type 1 and type 2 diabetes are risk factors for pneumonia-related hospitalization, and poor long-term glycemic control in patients with diabetes significantly increases the risk of hospitalization for pneumonia39. Several mechanisms may explain the association between hyperglycemia and postoperative complications. Hyperglycemia can impair immune cell function, reduce neutrophil activity, and decrease phagocytic capacity, thereby compromising the body’s ability to fight infection22,40. High glucose levels also potentiate inflammation and oxidative stress, which can increase tissue damage24,41. In addition, hyperglycemia can have direct effects on the lung by altering pulmonary endothelial permeability and decreasing mucociliary clearance, setting the stage for pneumonia38,42. Our study provides evidence that even mild hyperglycemia can trigger these deleterious effects and increase the risk of postoperative infection. An important finding was that the association between glucose levels and pneumonia differed between patients with and without diabetes. Non-diabetic patients are more sensitive to hyperglycemia and have a worse prognosis than diabetic patients. The inflection point for increased odds of pneumonia was lower in non-diabetics (5.81 mmol/L) than in diabetics (8.70 mmol/L). This supports the idea that acute stress-induced hyperglycemia is likely to pose a greater risk in nondiabetics than chronic elevated glucose in diabetics, which exerts a more gradual dose–response effect. As Bellis et al. found in patients with acute coronary syndrome, those with stress hyperglycemia tend to have worse outcomes than those with diabetes-associated hyperglycemia43. Guo conducted 3026 patients after minor stroke or TIA and found stress hyperglycemia may have a higher risk of stroke recurrence than previously diagnosed diabetes mellitus44. The exact mechanisms for this disparity remain unclear and warrant further investigation through prospective studies. Our findings highlight that even transient hyperglycemia associated with acute physiological stress may be detrimental, especially in patients without underlying glucose dysregulation. This has implications for tighter glycemic control and prompt antihyperglycemic therapy to mitigate adverse outcomes of surgery-induced stress hyperglycemia. It is reassuring to know that blood glucose levels are not only potentially predictive of the risk of POP after hip fracture but more importantly, can be modulated to reduce the risk of developing POP. There is substantial evidence that early glycemic control not only significantly reduces the incidence of POP after a variety of surgical procedures, but also lowers the occurrence of other adverse events and risk of mortality after surgery. Furnary et al. found continuous insulin infusion eliminates the incremental increase in in-hospital mortality after coronary artery bypass grafting associated with diabetes, and should become the standard of care for glycometabolic control in patients with diabetes undergoing coronary artery bypass surgery45. A randomized multicenter trial demonstrated that basal-bolus treatment with once-daily glargine plus premeal glulisine improved glycemic control and reduced postoperative complications such as wound infection, pneumonia, bacteremia, respiratory failure, and acute renal failure46. By implementing standardized protocols for frequent blood glucose monitoring and insulin administration, perioperative glycemic levels can be optimized within safe target ranges47. This approach may attenuate the exaggerated surgical stress response to hyperglycemia and ameliorate the detrimental effects of acute hyperglycemia on immune function. The interactions between the ASA classification and admission hyperglycemia suggest these comorbidities exacerbate hyperglycemia’s effects on POP(P = 0.016). Admission glucose levels were significantly correlated with postoperative pneumonia in patients with higher ASA classification, but not in patients with lower ASA classification. These underlying conditions make the risk role of hyperglycemia more pronounced48. Their synergistic adverse effects on recovery may partly explain higher rates of POP when both factors are present49. A nationwide cohort study found higher ASA scores were consistently associated with higher risks for urinary tract infections, pneumonia, second hip fractures, and heart failure50. In addition, according to the relevant literature51, false positives may occur when analyzing multiple subgroups, so the observed interaction between hyperglycemia and ASA classification requires further study. A better understanding of these synergistic risks will inform the management of complex patients. This study has several strengths. The sample size was adequately powered to detect significant associations between hyperglycemia status and POP. Confounding was rigorously accounted for through multivariate regression and PSM. The dose–response relationship analysis visualized the relationship between admission hyperglycemia and POP. This study uniquely examined how the association between admission glucose and postoperative pneumonia may differ based on diabetes status. Additional subgroup analyses evaluated potential effect modification by other clinical factors on the hyperglycemia-pneumonia relationship. Some limitations should be acknowledged. First, the retrospective single-center design means causality cannot be established. Residual confounding from unmeasured factors may also exist despite PSM. For example, patients with dementia and post-operative delirium are at risk of aspiration, which may be an important risk factor for post-operative pneumonia. Specifically, data on cognitive function and the occurrence of post-operative delirium were either missing or inconsistently documented across the patient cohort. This lack of standardized data prevented us from reliably incorporating these variables into our predictive model. Patients with dementia and post-operative delirium are at increased risk for post-operative pneumonia due to impaired cognitive function, reduced mobility, swallowing difficulties, compromised immune response, decreased consciousness during delirium, and poor nutritional status, all of which contribute to reduced lung expansion, secretion clearance, and increased vulnerability to infection. Additionally, we lacked data on specific glucose management strategies, which should be incorporated in future analyses. Third, we did not dynamically glucose levels during hospitalization and recovery. Changes in glucose over time may also be indicative of POP risk. Conclusions In conclusion, this study found that admission hyperglycemia is an independent predictor of developing POP in elderly hip fracture patients, with a dose-dependent relationship. This readily available laboratory measure may help clinicians identify surgical patients at increased risk of infection. Our findings highlight the need for tight glycemic control and prompt anti-hyperglycemic therapy to potentially improve outcomes in this vulnerable population. Supplementary Information Supplementary Information. Author contributions Study concept: YCL and WBD. Study design: All authors. Acquisition, analysis, or interpretation of data: WYT, WY, and WW. Statistical analysis: WYT, YHL,QML and WY. Drafting of the manuscript: WYT, XMN and DWB. Critical revision of the manuscript for important intellectual content: All authors. Funding The authors declare that no funds, grants, or other support were received during the preparation of this manuscript. Availability of data and materials All the data used and analyzed during the current study are available from the corresponding author upon reasonable request. Declarations Competing interests The authors declare no competing interests. Ethics approval and consent to participate This study was approved by the Ethics Committee of Dandong Central Hospital (No. DDZX-202401103) and conducted by the ethical principles outlined in the Helsinki Declaration of 1964 and its subsequent amendments. Written informed consent for participation was not required from the participants or the participants’ legal guardians/next of kin in accordance with the national legislation and institutional requirements. Consent for publication We have obtained consent for publication from all participants. Footnotes Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations. Supplementary Information The online version contains supplementary material available at 10.1038/s41598-024-78343-0. References Associated Data Supplementary Materials Supplementary Information. Data Availability Statement All the data used and analyzed during the current study are available from the corresponding author upon reasonable request.