The U.S. Supreme Court dealt a blow today to nascent efforts to track the quality and cost of health care, ruling that a 1974 law precludes states from requiring that every health care claim involving their residents be submitted to a massive database.

The arguments were arcane, but the effect is clear: We’re a long way off from having a true picture of the country’s health care spending, especially differences in the way hospitals treat patients and doctors practice medicine.

It also means that, for the time being at least, we’ll remain heavily reliant on data being released by Medicare, the federal health insurance program for the elderly and disabled, to study variations in health care. ProPublica has used Medicare data to study differences in medication prescribing,surgeons’ complication rates and use of services by doctors, but it’s still not clear that Medicare is representative of all health care in the country.

The court’s decision involves a case from Vermont, one of 18 states that created so-called all-payer claims databases. Vermont’s law called for health insurers, health providers, medical facilities and government agencies to report data on health care costs, prices, quality and use of services to the state. That included employers who pay the costs of their workers’ treatments themselves, and not through an insurance contract. (Self insurance is common for large companies.)

But Liberty Mutual Insurance Co. objected, saying the Employee Retirement Income Security Act of 1974, or ERISA, prevents states from imposing such a requirement on self-funded plans. The idea is that companies that have operations across the country shouldn’t be subjected to 50 different state laws, but instead should only have to abide by rules from one agency, namely the U.S. Department of Labor.

The court sided with Liberty Mutual, in a 6–2 decision, ruling it did not have to submit the data demanded by Vermont.

In a friend-of-the-court brief filed last September, the American Hospital Association and the Association of American Medical Colleges said that without the data from self-funded plans, all-payer claims databases will be incomplete and not as valuable as they could be.

“Hospitals only have data for the patients they treat,” the groups wrote. “Information from across the spectrum of an individual’s health care experience is needed to inform clinical, payment, and public health policy…Complete data across all payers (including self-insurers like Respondent) is required so that both health care providers and policymakers can understand the variations in the health care system, and address those that need to change.”

They also noted that self-insured plans cover a “large majority of the working population: in 2013, nearly 60% of workers with health insurance were enrolled in such plans, and that figure is growing.”

So what now? One option is for self-insured plans like Liberty Mutual to voluntarily provide their data to state-run databases. But given the lawsuit, that appears unlikely.

Another possibility, raised by Justice Stephen Breyer, is for the federal government to require self-insured plans to disclose their data. “I see no reason why the Secretary of Labor could not develop reporting requirements that satisfy the states’ needs, including some state-specific requirements, as appropriate,” he wrote.

For now, though, we may have to do what we have done for years: Settle for an incomplete picture of health care spending and utilization.

Our team at ProPublica has already found fascinating patterns in Medicare data. In one example, 1,800 doctors billed Medicare for the most expensive type of office visits at least 90 percent of the time, compared to just 4 percent of office visits for all doctors.

Another group, the Health Care Cost Institute, has greenlighted research using data from three of the nation’s largest private insurance companies. It has found some interesting trends too, but hasn’t released data on individual doctors and hospitals.

Medicare could release more data, as could the Health Care Cost Institute.

The Supreme Court decision means transparency has a long way to go.