A peptic ulcer is erosion in the lining of the stomach or the first part of the small intestine, an area called the duodenum. If the peptic ulcer is located in the stomach it is called a gastric ulcer.