Appendectomy for an inflammatory condition (appendicitis or lymphadenitis) but not for nonspecific abdominal pain is associated with a low risk of subsequent ulcerative colitis. This inverse relation is limited to patients who undergo surgery before the age of 20 years.
Andersson et al. (2001) studied this question.
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: