ERCP (endoscopic retrograde cholangiopancreatography) is a procedure that evaluates and treats disorders of the pancreas, liver, gallbladder, and bile ducts. It is performed with an endoscope, which is a long flexible tube with a light and camera at the end of it. The tube has a channel that allows the physician to pass instruments through it in order to aid in diagnosis and treatment, as well as take tissue samples. Common reasons to perform ERCP include gallstones stuck in the bile duct, infections and leaks of the bile duct, and tumors of the pancreas and bile ducts. ERCP is done while the patient is sedated. It is generally a safe procedure, although complications such as bleeding, pancreatitis (inflammation of the pancreas), and tearing of the digestive tract can occur.