Severe pain in my rib cage & back, 36 weeks pregnant!

So last night I had this severe aching pain in my rib cage and the back of my ribs that didn’t go away in any position I would move in. I’m a FTM and 36 weeks pregnant, and I am also aware of Braxton Hicks contractions (as I have had them on & off since I was 30 weeks pregnant) and I know that real contractions are constant and regular, which I’m not sure if what I experienced last night was a real contraction or not? The pain didn’t go away at all until after a couple minutes of me sitting upright on my bed. And I haven’t felt that pain again so I am sure it wasn’t a contraction, but I plan on asking my doctor tomorrow at my 36 week check up. I just want to know if anybody else has felt this before? Sorry if I don’t make much sense, I usually only ask my doctor at my appointments, but I just wanted to know if any other mothers have felt this before.