Pinched nerves, gastroesophageal reflux disease all can cause pain in upper back.
Burping is most often caused by swallowed air
and commonest cause is gastro esophageal reflux disease. Burping which occurs with other symptoms like pain, heartburn, nausea, a decreased appetite, or weight loss may be associated with a serious cause. Take light food. Avoid fried spicy food. A clinical examination is must for correct diagnosis and management. I hope it helps.
Best wishes and kind regards!