Sudden stomach pain lasts for a few days may be due to the existence of gastric ulcer, gastritis, gastric cancer and so on. 1. Gastric ulcer: due to Helicobacter pylori, stress mental factors, irregular diet and other reasons can cause the occurrence of gastric ulcers, gastric acid damage to the gastric mucosa to form ulcers, stimulate the nerves to produce pain in the stomach, such as untimely treatment may continue to ache for several days. 2. Gastritis: Gastritis patients may stimulate gastric mucosa due to inflammation, which causes stomach spasm, thus leading to stomach pain, which is mainly hidden pain, distending pain, burning pain and so on. 3. Gastric cancer: the occurrence of gastric cancer is generally related to heredity, Helicobacter pylori infection, etc. Most of the patients do not have obvious symptoms in the early stage, while in the middle and advanced stage, gastric cancer may present symptoms such as stomach pain, loss of appetite and weight loss, vomiting blood and black stool. There may be other reasons for sudden stomach pain that lasts for several days, so you can go to the hospital for examination to clarify the situation.