But be wary retreating, if you do so, you automatically give your enemy 3 experience points, which in most cases mean they get an automatic upgrade.
This is changing in patch 1.2 in multiplayer so it's same as if they had just won the battle normally, but will remain 3 experience points in single player.
Sometimes have to decide if its worth saving the unit or not.