It's nothing of the sort. Shit, they don't even know the mechanism of action of most existing drugs, and diagnosis for anything off the beaten path is just guessing most of the time. Don't get me started on dietology and psychology / psychiatry either. People practicing (and charging a lot of money!) in those fields have no fucking clue whatsoever. Both my wife and I have been misdiagnosed with some severe, incurable shit, which threw us for a loop before we figured out that an MRI can, in fact, result in a complete mis-diagnosis. My wife in particular was told she has like 5 years until she'll need a wheelchair due to a spinal cord abnormality. As you can imagine we took the news pretty hard. Yet in a repeat MRI 2 years later another doctor did not see this (incurable!) "abnormality".
Stop treating doctors as these infallible oracles that know WTF they're doing 100% of the time. Just because they paid $300K for their diploma and studied for a decade to get it doesn't mean they're infallible. At best, they know what they're doing most of the time. At worst, they can cause harm: medical errors are the third most prevalent cause of death in the US, right after heart disease and cancer.
That's not to say you should take your medical advice from a forum or, god forbid, Facebook. Doctor is still your best option 100% of the time, medical error fatality rate notwithstanding. It's just to say that it's not as precise a science as people make it out to be.