A Pyrrhic victory is a victory which is only achieved with heavy losses on one's own side.
This alludes to the Battle of Ausculum (Ascoli Satriano, in Apulia). in 279 BCE, when the Epirote King Pyrrhus, aiding the Tarentines, defeated the Romans but with severe casualties of his own. After the battle, Pyrrhus is recorded to have commented: "If we win another such battle against the Romans, we will be completely lost" (Plutarch, Pyrrhus 21,14).
The world wars could be loosely considered Pyrrhic victories.
The best example of a pyrrhic victory is in the anglo-zulu war, in which Ntshingwayo Khoza set 22,000 zulu warriors, about 55% of the male population of zululands to attack 1,400 British soldiers in a surprise attack at the Battle of Isandlwana.
Although less than 100 soldiers escaped survived, 4000 zulus, about 10% of the entire male population were lost or substantially wounded in defeating a poorly maintained and inexperienced third of the army in the area. To make matters worse for king Cetshwayo, later that day a force of 5000 zulus took on a hospital with 142 men in it, including all ranks. The zulus, amred with weapons from the earlier pyrrhic victory failed to do any more than kill 17 soldiers and wound 15. This was at an expense of almost 1000 soldiers.