How long to take medication for stomach disease depends on the specific situation, generally speaking, gastric ulcer is 6 to 8 weeks, duodenal ulcer is 4 to 6 weeks. For the existence of gastric disease, if the diagnosis of gastric ulcer, it is recommended that patients take proton pump inhibitors, mucosal protective agents, such as omeprazole, magnesium aluminum carbonate, etc., it is recommended that the course of treatment for 6 to 8 weeks, and if the diagnosis of duodenal ulcers, it is recommended to take the drug for about 4 to 6 weeks. If the infection of Helicobacter pylori exists, it is necessary to take drugs for the treatment of Helicobacter pylori for 2 weeks and continue to take acid-suppressing drugs for 4 to 6 weeks. Such as amoxicillin, clarithromycin, omeprazole, bismuth pectin and other drugs. It is recommended that patients with gastric problems go to the hospital in time to improve the relevant examinations, such as gastroscopy, in order to clarify the diagnosis, and then medication, medication under the guidance of a doctor.