Jonathan Bernstein and Matthew Yglesias have posts discussing why Democrats prioritized health care reform over climate change, when the latter is a more urgent and time-sensitive issue than the latter. I think Yglesias has a strong point that the disparate regional impact of climate change legislation made a partisan bill impossible, and the intense legislative cohesion of the Senate Republicans made a bipartisan bill impossible.
I think a factor neither of them considers is public opinion. I think the most telling measure might not be direct measures of public opinion but the body language of politicians. On health care, Republicans were forced to concede that there is a problem. They almost entirely dropped their "best health care in the world" talking point, and insisted over and over that they simply want a different health care reform bill, one that has all the popular elements without the unpopular elements. Very few elected Republicans were willing to openly defend the idea that if you can't afford health insurance it's your own damn fault, even though many conservative elites clearly believe it. The public considered doing nothing an unacceptable option (which is also why most Republicans are keeping their distance from repeal.)
On climate change, by contrast, the opinion landscape looked a lot like it did with health care in 1994. Support for action is very soft. Large majorities of Republicans deny that there is a problem at all -- either they don't accept climate science, or they insist the cost of reducing emissions is prohibitive. Republicans obviously perceive no electoral cost to a straightforward rejectionist stance.
Again, the issue here is not so much Republican behavior -- all Republicans wound up rejecting health care reform -- but what Republican body language says about public opinion as a whole. It suggests, I think, that Democrats felt the costs of failing to reform health care would be high, even if the costs of reforming health care would also be high. The costs of failing to pass a climate bill are low.
There's also a fact I keep pointing out that seems to me to be getting short shrift. I don't see the effort to reduce greenhouse gasses as having failed. I think it's simply switched forms. Basically, the Obama administration tried to craft a bill that did the most efficient job of reducing the costs of limiting carbon emissions. That having failed, the new approach is to do the most efficient job of hiding the costs of reducing emissions. Thus we have a combination of subsidies for green energy and EPA regulation of carbon dioxide emissions. Those measures are popular because, despite being less efficient than a straightforward tax or carbon cap, they obscure the costs to consumers. Indeed, if I were a vulnerable elected official, I might prefer to push the policy mix in this direction as well.