Whats better for your health medical marijuana or prescribed pills?

For what problem? The problem with medical marijuana at least in my state is no regulation or real diagnosis is needed to recieve it, one time visit for licence, then its pick your flavor at the dispenceries. No follow up in many cases. Opiate medications can be problematic as well. Many diagnosis would not require either if properly evaluated. For chronic pain opiates can be a great tool, but not a cure all.
Neither. ..? The answer really depends on the type of pain - its not a simple answer. Thc is federally illegal (irrespective of individual states). Marinol is legal but costs a lot more. Regular "pills" are not always a solution to a persons pain. A complete evaluation is necessary. If one joint helps then two joints will help more?
Pain treatment. Marijuana is illegal under federal law. It has been legalized under some state laws but federal law trumps state law. Appropriately prescribed medications for an appropriately diagnosed condition are usually effective in controlling the targeted condition.