What is this foul gas?

I recently had a bit of a sour stomach, caused by something I ate or drank (a variety of Mexican dishes, bratwurst and several beers). I didn’t feel anything, but the next day I had to belch a few times, resulting in a sour taste in my mouth and a hellaciously foul, and I do mean foul, odor in the air. (This was also accompanied by mild diarrhea.)

What gas with this characteristic would be produced in the stomach?

All you’ve given us to go on is “foul-smelling gas produced in the digestive system”, and you expect us to name one specific gas based on that? There are probably hundreds that fit that description. In what way was it foul? Did it smell like rotting meat? Feces? Ammonia?