I thought I had it down after these comments, but now I'm realizing there's never iron on any of these maps. In civ 4, only like 1/4 starts had no iron nearby, but now it seems like this is 1/2. So, you have to trade, or make nice with an iron city state. So, I did this, built a ton of swordsmen, tried to attack my neighbor, and he had lots of pikemen, which quickly decimated me. I guess I now just have to wait to out-tech him, and then upgrade the swords to guns
I would not fight an early war with only Swords and no Comp Bowmen. Really, you'll be a lot better off with 4 Comp Bows and 2 Swords than 6 Swords (needs less Iron, too!). The goal of the swords is not to deal damage but to prevent their pikes from attacking your Comp bows (so they should do things like fortify and pillage, not attack). Eventually all their troops are dead.
Melee units are also really terrible for taking cities (except battering rams and siege towers), and IMHO so are Catapults, they just don't do enough damage and die too easily, especially against a Tradition civ. I don't like to war early, but if you must do it, do it with Comp bows.