It depends on many factors, including the weight of the sword, the force behind the blow, the direction of the blow, and the quality of both weapon and armor. Let's assume "default D&D" quality for the armor and sword; that is, they are both made of unexceptional but durable steel.
If you aim a really powerful, chopping/hacking blow at a chain-armored target, and the target isn't dodging or twisting out of the way, then you could conceivably chop through quite a few links and drive the broken pieces into the target. A full-strength longsword chop downward upon the collarbone/shoulder of an unaware target could produce this kind of result.
If you aim a moderately powerful, thrusting/piercing blow at a chain-armored target, and connect, you could conceivably run the target through with only moderate interference from the armor (depending on the breadth of your blade). A medium-strength rapier lunge to the midsection of a surprised target could produce this kind of result.
If you aim a casual, slicing/slashing blow at a chain-armored target, you could conceivably run your sword along the armor and not even hurt the target. A light slash across the arm of an aware and active target could produce this kind of result.
Plate armor is even better against slicing maneuvers and chopping maneuvers, and somewhat better against piercing maneuvers. Greatswords would seem to be pretty handy for chopping through plate armor, because of their weight and length (leverage/momentum). It is thought in some quarters that the flamberge-type blade is even better, in that it concentrates chopping power into a few impact points.
In addition, part of the advantage of plate against most attacks is that it is hard to hit "straight on," so that a properly-delivered point or edge which would ordinarily pierce the armor will instead be deflected off to one side. I imagine D&D's armor proficiencies include training in how to move so that the armor "does its job"; this would be true of all armor types.
One thing chain armor is really abysmal at is protecting the wearer against heavy, blunt blows (plate, again, is somewhat better). The armor deforms right along with the delivery of force. Its weight, and the padding underneath, will surely dampen the severity of the blow, but let's face it, it's just hard to avoid a good clobbering unless the attacker misses altogether.
