There are varied reasons for joint pain.. How many days have passed since this problem started..
Loss of lordosis is due to muscle spasm. That may cause stretching pain but not joint pain..
Next Steps
If it is happening for a few days only, you can start with hot fomentation, analgesic tablet,
calcium and vit d supplements. If many days have passed and ot is it getting relieved, I will suggest you to get some investigations done for ruling out any inflammatory pathology of joints..
Health Tips
Hot fomentation can be done along with active joint movement exercises..