In medicine, melaena or melena is the passage of black tarry motions per rectum (dark black feces). It is often caused by hemorrhage in the stomach or duodenum (upper gastrointestinal tract ), for example by a peptic ulcer. The black color is caused by the iron in hemoglobin that is oxidized during its passage through the ileum. An EGD is usually performed to diagnose the cause.
Melena is great diagnostic aid. If the bleeding is in oesophagus or mouth then pacient will vomit the blood. If the bleeding is from ileum or colon, feces will be mixed with red blood because iron won't be oxidized. If the bleeding is from anus, feces won't be mixed with blood only covered. Only if bleeding is in stomach or dudenum, pacient will suffer with melena.