Let's have a discussion about which wars we should consider the US to have lost.
We are going to simply exclude the Civil War from the debate since it's not worth getting into the semantics. Also exclude silly "the war on xxx" things like the war on terror.
So my tally is:
1 loss (Vietnam)
2 draw (Korea, War of 1812)
1 ongoing (Afghanistan)
1 currently undecided (Iraq)
Wow, so wrong here. In reality, we lost 1, that is the War of 1812. And yes, we did indeed loose that one. The UK was distracted fighting France for most of that war, and never really took the field of battle against us. And we lost pretty much every battle during the war (other then one wafter the war was over), and we indeed sued them for peace. In military terms, that is considered to be a "loss".
Now for the others, let's cover them one at a time, in chronological order. And remember, what is important in any war is achieving your goal.
Now the Korean War, what was the goal? It was simply protecting South Korea from invasion from North Korea. Now where were the forces at when the war ended? Well, technically it is still going on (a big miss of yours, that is still an ongoing war believe it or not), but the DMZ is North of where the original border was. TO pretty much everybody, that constitutes a win.
Now in Vietnam, that is unquestionably a US military win. At the time of the Paris Peace Accords, North Vietnam was on the brink of crumbling, and they were the ones that sued for peace. And the US accepted the agreement in 1973, and agreed to pull combat forces out of South Vietnam if North Vietnam agreed to recognize the right of South Vietnam to exist, stop all guerrilla actions against South Vietnam, and conduct a unilateral drawdown of forces along with South Vietnam.
Well, we all know the outcome of that. South Vietnam agreed to the conditions, North Vietnam broke them, and in 1975 invaded and destroyed South Vietnam. Almost 3 years after the last US combat forces left. So how that is a "loss", I have no idea.
Now with Afghanistan, once again what was the goal? I seem to remember it being the elimination of al-Qaeda, and the Taliban as the ruling government. Now they are still fighting over there, but al-Quaeda is indeed gon, and the Taliban have not been in control for over 15 years. So once again, a win.
Now on to Iraq. Once again, what was the goal? It was the removal of the Ba'ath Party with Saddam Hussein controlling the country. Was that or was that not done? Simple question, if it was then the goal was achieved. Does anybody see the Ba'ath Party regaining control of Iraq in the next couple of centuries?
What you are confusing here is winning the war, with establishing a stable nation. Nation building is not the job of the military. Never has been, never will be. You might as well add in there Lebanon, since the US was involved there also, and it is still an unstable mess even half a century later. Or Haiti.
Now the goal for war is simply to destroy the fighting will or capability of the other side. And other then the War of 1812, we have done that every single time. But once that goal is completed, there are many more variables involved in what is to take the place. So it is not winning a war that is a problem, it is ensuring that the peace remains that is the real problem.
But do not confuse the two. And learn what actually makes a win, loss, and draw when it comes to a war. Like far to many, you are trying to pose a military question, but framing it in political wording. And even then, you missed at least one very big one, and recorded it as a draw when actually it was a loss.