I understand what you mean, I usually attack enemy city with 3 range unit and 3 mele or more (in condition I already kill most of their unit near my city border, well they will spend their gold on buying new unit to defend it, sometime it can be also cause a problem, thats why I always produce new unit and accumulate it when I'm in the state of war in case if I do a wrong move, it don't totally fail my siege), mele walk infront each range unit, to anticipate any direct attack to my range unit. So when the mele unit start to enter city border and enter the attack range (while my range unit still outside from their attack range) they start to shot my mele unit. and I directly heal, while the other unit walk infront of the city, I order the mele to fortify while the range unit start the siege, and enemy unit focusing to shot wounded unit.
There are only some possibility that your unit die before it approach enemy city that rely their defense only with city arrow and a garrison range unit,
1. When your unit get wounded, you keep them active on the siege instead stop for healing.
2. Their technology way to advance from yours.
I always promote my unit with something that can enchant the healing, so when it walk with formation, it becoming stronger (I always go on honor) and heal more wounded. Another tips, use swordman when you go on siege, they are stronger on taking arrow damages, they really works as your tanks. Maybe you can post the picture and also your difficulty level. In vanila I play in high difficulty level, but in the new expansion honestly speaking I still try the difficulty so I play on prince, but it is so easy for me, but comparing to vanila prince the AI is indeed smarter and harder. But with these tactic I easily win the war in civ 5 vanila on emperor level.