Answer
Military defeat led to Prince Andrew's second exile due to his failure to adequately prepare and strategically command his troops during a crucial military campaign. This resulted in significant losses and brought about a loss of confidence in his leadership among his superiors and fellow soldiers. Consequently, as a form of punishment and to mitigate further potential damage, he was removed from his position and exiled for a second time.