Hi there.. shoulder pain with upper backpain has many causes like poor posture, trauma, hard mattress and pillow, degenerative diseases( cervical spondylosis, cervical disc prolapse), tumors, muscle strain, joint and bone abnormalities. Please get X-ray done once. Do regular shoulder exercises, don't use pillow while sleeping or use soft pillow. Keep changing postures often. Don't lift any heavy objects over head, neck or shoulder as that wil put more pressure over muscles and increase your pain. Hot fomentation, gels with diclofenac for local application and tablet aceclofenac 100mg twice daily for 2 days. If still pain doesn't reduce then Please consult orthopedician in person once..