Lots of good advice on here.
Sounds like sciatica.
Physio is best.
Sadly no short term fix. Discs don't pop in and out but rupture and extrude a gel with the consistency of a haribo chew, which then takes weeks and months to be remodelled by inflammatory cells into something more like its pre-morbid anatomical shape.
In order of strength- ibuprofen, diclofenac, naproxen.
Similar anticipated order of worsening gastric side effects including gastritis and ulcers.
Actually heartwise, naproxen is safer than the weaker diclofenac though I don't suppose you'll be wanting to use any of these for too long and you're not likely to have ischaemic heart disease either. There are also kidney effects to take into account.
Take all of the above with food, don't exceed normal doses and if taken with paracetamol they work synergistically to the extent you actually need less nurofen/ diclo/ naproxen for the same effect.
Codeine and tramadol have their place but their own problems.
If you are using something long term for nerve pain talk to your dr about Lyrica.
But none of this substitute for physio.