I too experienced similar pain in my upper rib cage area. It seemed to be right in the rib. I am male. None-the-less, this last for a longtime, probably a year - it would come and go. At times the pain was so bad I couldn't sleep for days.
I under went every test you can imangine - chest xray, ultrasound, bloodwork - nothing showed up. I thought for sure I had a cancer. I now think it was some short of viral infection - but who knows. The Dx was maybe pleurisie(sp?). All I did was worry myself sick, literally. I soon after developed wierd sensory neuroapathy symptoms which i believe were stress related to the pain in my chest area. Antidepressant drugs seem to work me.
Know that you are now alone out there. Wish I could be of more help.