Migraines and meds?

I've always had migraines but yesterday was the worst one of my life! My doctor said I can't take anything to get rid of it, I'm just suppose to put a cold washcloth on my head and relax. That definitely didn't work, it lasted over 12 hours. Does anyone else get bad migraines and does your doctor allow you to take any medication for it?