Some glands in the stomach and duodenum a segment of the intestine secrete mucus to protect the lining of the digestive tract from stomach acid. If the balance breaks down, the gastric juices can begin to eat into the lining of the stomach or intestinal wall.
Over time, this corrosion can lead to an ulcer.
Gastroesophageal reflux disease GERD, however, is different from an ulcer and is a disorder in which the contents of the stomach or small intestine move back into the esophagus.