My stomach has hurt for 15 years. I have been to many doctors and have pretty much given up on doctors.  I gave up dairy and feel a little better but recently I wake up with a sharp pain in my lower abdomen on my left side and my back hurts so much it wakes me up and I almost cry when I try to roll over in bed.  The abdominal pain feels like it did before I had my appendix out buy on the wrong side. Once I have a BM I feel much better but it is usually with 30 minutes of struggle. My stools are not hard but strenuous, painful and I usually dont feel like I gave completed the job and often wonder if it is obstructed. I also get very bad heartburn and occasionally burp up foam that usually tastes bitter like bile.
You might be suffering from food allergy may be milk wheat potato or any food taking as usual manner can get blood serum test for food specific antibodies for milk wheat potato rice nuts and eggs get elimination diet and this will work on you as nobody thinks in this way of disease which I have used o treat many patients like this in my center