I think TF2 is the most balanced class based game I've ever played. Lots of people don't know how to play certain classes (Medic mainly), but I can't think of a bad class overall. Personally I can't play Scout to save my life (I play Spy). Some classes take some time to grasp the subtleties; there can be a real sharp learning curve for first time Engineers, and Spies in my experience.
I'm tempted to say Soldier as the slow reload times means if you botch your first shot then you're at a loss. The same, however, could be said for the Spy as they are weak in 1 on 1 combat, and rely on the element of surprise, but I've made plenty of kills, and wins practically on my own as a spy. The Medic is a poor ranged combatant, but then you'd be playing him wrong, again, however, I've made loads of kills as a Medic and find their Syringe gun great against cloaked Spies, and fast moving Scouts if there's not a Pyro around.
I, unfortunately, have the PS3 version so maybe the updates have shifted the balance, but there are no bad TF2 classes, only bad players.