" This is what winning looks like," President Trump said Tuesday about the spending bill that will fund the federal government through the rest of the fiscal year.

It was an odd statement, given how Democrats, who control neither the House nor the Senate, got almost everything they wanted in the package and Republicans, including Trump, got almost nothing.

The bill included $5 billion in extra domestic spending, protected taxpayer subsidies for abortion giant Planned Parenthood, extra money for Puerto Rico and Medicaid, no money for a border wall, and a smaller defense hike than requested.

"I think the Democrats cleaned our clock," Republican Sen. Lindsey Graham told the Washington Post. "There are things in this bill that I just don't understand. This was not winning from the Republican point of view."

So how does Trump call it winning? How does Mick Mulvaney make the same argument?

Here's how:

Republicans actually did obtain their primary goal, which is the top priority of GOP congressional leadership at all times: No government shutdown.

This is the prime directive of GOP leadership.

No government shutdown.

Republicans will always bear the blame for a shutdown. Chalk it up to media bias, the fact that Democrats love government and so its not credible to blame them for shutting it down, or now the fact that the Republican president has called for a government shutdown. The single largest motivating factor for Republicans is that the government doesn't shut down.

Once you understand that, you can understand most of what has happened in Congress since the 2010 elections. In general, Republicans have caved to Democrats on spending deals. Ted Cruz is the single most hated Republican. The Freedom Caucus is reviled by the establishment. Most Republican behavior in recent years if you see the party as a party with one goal: avoid a government shutdown.

So it's a compromise, you see. Democrats get their money for the abortion lobby, they block money for Trump's top priority, and they get their higher price tag; and Republicans get no government shutdown.

Timothy P. Carney, The Washington Examiner's commentary editor, can be contacted at tcarney@washingtonexaminer.com. His column appears Tuesday nights on washingtonexaminer.com.