Hammer Nutrition have put together a great article explaining how to deal with stomach distress.

This is most likely to happen during a race due to the increase in pressure on the digestive system as your blood flow is directed to the working muscles.

They advise:

Remove all processed simple sugar based fuels from your training and events. Processed simple sugars create havoc on the entire digestive system and body, which increases the stress placed on the body.

Try to run on an all-liquid diet for events under 24 hours in duration as solid food slows down the digestive system and removes blood from the working muscles.

Reduce the number of calories consumed in an hour. Yes you might be burning 800 calories an hour, but trying to replace even half of that is too many calories.

Further Reading:

  1. Fructose Sweeteners Negatively Impact Blood Sugar and Lipid Metabolism Inhibiting Energy Production and
  2. 146 Reasons Sugar Ruins Your Health
  3. Reducing the possibility of stomach distress