Pittsburgh Sleep Quality Index score (odds ratio [OR] = 1.084, 95% confidence interval [CI] = 1.024–1.147, P = 0.005), preoperative albumin level (OR = 0.945, 95% CI = 0.905–0.988, P = 0.012), digestive diseases (OR = 1.084, 95% CI = 1.024–1.147, P = 0.005) and total hip arthroplasty (THA) (OR = 0.273, 95% CI = 0.170–0.439, P < 0.001) were predictors of LOS ≤ 2 in the multivariate logistic analysis model. Here, ALB is linked to digestive system disorder.