Acute intermittent porphyria (AIP) is caused by a partial deficiency of hydroxymethylbilane synthase and affects heme biosynthesis. This evidence concerns the gene HMBS and autoimmune pancreatitis.