You need to visit a dentist and get proper checkup done. Jaw pain can due to decayed tooth (tooth pain & swelling due to infection) /wisdom tooth/any trauma from past/tmj joint ,without seeing condition of your mouth no one can tell you the exact reason of jaw pain.
Next Steps
Visit your Dentist and get proper checkup done .
Health Tips
Don't take medicine blindly and get your dental checkup done.