If your pain is located smack dab in the center of your buttocks cheek, and is giving you trouble sitting and going up stairs, you very well may have a tight or inflamed piriformis muscle. It is a deep muscle that enable external hip rotation.
Here is a video by the posturedoc that explains a way to relieve the symptoms of a tight piriformis. It’s how to do Chair Pigeon Pose correctly. If you are my student, you will know this is highly recommended since we go over it in class frequently. Even if you don’t have a tight piriformis, it”s a great pose to stretch the hips.
A consistent practice of stretching that muscle (including Happy Baby, Thread the Needle, and Pigeon) will go a long way towards preventing further occurrences. As always, though, get advice from your medical practitioner and Don’t OVERDO!
Here is a video stretch by an osteopath from UK that demonstrates clearly two stretches. Though he does not call them by their yogic names, I can tell you that the first is (don’t laugh) Gas Relieving Pose, and the second is the third part of Supta Padangusthasana that is not often taught and if it is, is taught in a slightly different version called, Rock The Baby.