I think they call that gastro pareisis. I have it too. If I eat something I shouldn't, it can take 3 or 4 days for it all to move through. Even when I had a capsule endoscopy it didn't move through in 8 hours on an empty stomach. My GI couldn't believe the camera stopped working before it cleared the small intestines. My second colonoscopy this year produced tremendous pain in my belly and my chest for several days. It eventually went away but for a while I thought I was having a heart attack. Once the gas started coming out, I got relief every time I went to the bathroom which wasn't that often.
My IBS sometimes results in days of pain if I eat something wrong. I had two slices of pepperoni pizza and thought I would die for 2 days.
Since I have cut out gluten and candy and have stuck to rice or corn cakes instead of bread I can sleep at night without pain.
Presently on: 600 mg. Remicade every 5 weeks
Venofer infusion every 5 weeks
B12 every 5 weeks
15 mg. Methotrexate/injection weekly
12 Asacol daily
10 mg. Celexa daily
Zofran as needed