Which was the last war in which swords were actively used as the primary weapon by an army?
During the WWII Russian, Polish, German, French and Italian cavalry regiments existed. And they really used swords. The use against tanks is obviously a fallacy, but in the sudden attacks against infantry the swords worked!
So, these armies had not only CARRIED swords, not only USED swords, but even COUNTED on them in battle!