Пор
However, during his reign as emperor many losses were inflicted on his kingdom by the Ghaznavids. During the battle of Chach between Mahmud and Anandapala, it is stated that "a body of 30,000 Gakhars fought alongside as soldiers for the Shahi Emperor and incurred huge losses for the Ghaznavids". However, despite the heavy losses of the enemy, he lost the battle and suffered much financial and territorial loss. This was Anandapala's last stand against Sultan Mahmud of Ghazni. He eventually signed a treaty with the Ghaznavid Empire in 1010 and shortly a year later died as a result of a natural death. R. C. Majumdar compared him ironically to his dynastic ancient famous ancestor ""King Porus", who fought Alexander. And "Tahqíq Má li'l-Hind" finally revered him in his legacy as "noble and courageous".