Stomachache and back pain

Patient: I have stomachache and some times pain shifts to the back, at some spot near the spinal cord. i have tested and its not ulcers or an infection in the stomach. what could this be

Symptoms: only stomachache

Doctor: