Yesterday, a judge's ruling on the patents on Merck's (NYSE: MRK) blood pressure medications Cozaar and Hyzaar benefited both Merck and the plaintiff in the suit, generic-drug maker Teva Pharmaceuticals (Nasdaq: TEVA). That's because the defendant in the suit wasn't actually Merck but the Food and Drug Administration.

We'll have to go back to 2003 and 2004 to sort out this mystery. Teva won a suit against Merck that invalidated some of the patents on the drugs, but not the patents that give Merck exclusivity until April 6. Invalidating the latter patents earned Teva a 180-day exclusive period for selling the drugs under the Hatch-Waxman law.

Merck then removed those invalidated patents from 2003 and 2004 from the FDA's "orange book" where patents are listed, so the FDA took away Teva's exclusivity and planned to give anyone that had a valid application the right to sell the drug next month. Teva sued the FDA to get its exclusivity back. It lost in a lower court in July, but appealed the decision and won yesterday.

There are big bucks involved here. Merck sold a total of $1.3 billion of Cozaar and Hyzaar in the U.S. last year. Teva would obviously like to keep all of what they can get from that to itself during the first six months instead of fighting for market share with the four other generic-drug makers -- including fellow heavyweight Novartis (NYSE: NVS) -- which all currently have tentative approvals to sell Cozaar and Hyzaar.

In addition to greater revenue without the extra competition, Teva will be able to keep the price up. One survey of generic drug prices by the FDA showed that generic drug prices were 94% of their branded counterparts when there was only one generic offering, but that number dropped to 33% when the competition increased to five players.

The high price should help Merck as well because it could mean less conversion to the generic. Merck could also launch an authorized generic of its own and try to grab some of the market while Teva's the only other player.

This isn't the first issue of lost 180-day exclusivities for Teva. Last year it sued the FDA over the same issue with patents on Johnson & Johnson's (NYSE: JNJ) Risperdal being removed from the rolls. It seems the courts haven't made up their mind about the legality of the issue; in that case Teva won in a lower case and then lost in a higher court.

With high-margin bonuses on the line, first-to-file opportunities are very important to companies. Teva says it had 89 at the end of the year, while rival Mylan (Nasdaq: MYL) said it had 40. Teva, Mylan, and the rest of the industry hope that the latest ruling is the one that sticks.

Not satisfied with generic returns, these Fools ask why you're not earning 50% annual returns.