King Parikshit, the grandson of Pandavas, was killed by Takshak, the king of snakes. When Janmejaya, Parikshit’s son grew up and became king, he decided to avenge his father’s death. Along with Rishi Uttank, Janmejaya did yagnya for the end of all snakes. Rishi Uttank would say some mantra and offer the snakes to the fire “swaha”. Tens of hundreds of snakes would come and fall into the burning fire. The yagna went on for many days.
A group snakes that were still alive went to their king Takshak for help. Takshak knew the yagna was to kill him to avenge King Parikshit’s death. However, instead of helping the other snakes, he went to Lord Indra to seek refuge. Indra granted him asylum.
As the yagna proceeded more and more snakes were sacrificed every time Rishi Uttank said “swaha”.
Meanwhile the pull of the mantras could be felt by Vasuki, the snake that helped devas and asuras during samudramanthan. He went to his sister Jaratkaru for help. “Sister, you have to help us. The pull of the mantras is too strong for me. I feel like I am on fire, and I can only imagine the plight of the other snakes. According to Brahma, your son Asteek will save our clan. Please send him to Janmejaya’s yagna and ask him to stop.” “Asteek is but a mere boy. How can he stop the yagna?” Jaratkaru asked. “Asteek may be young but he is very knowledgeable and knows all the vedas. When you were married, Brahma had predicted your son would save our clan. Do not worry, send Asteek.” Jaratkaru agreed and sent Asteek to Janmejaya.
Asteek was not allowed to enter the yagna. So he began to sing praises of King Janmejaya. Hearing his melodious voice, the King met with him. Asteek began to sing the Vedas and the Mahabharata. Janmejaya was impressed. “I am impressed with you and will give you in gift whatever you ask. Please ask for anything, son.”
In the meanwhile on the yagnya floor, Uttank was chanting mantras to bring in Takshak, but to no avail. Then an informant informed that Takshak had taken refuge with Indra and was being protected by him. Uttank was furious; he chanted mantra, “Indray Takshakay swaha”. Meaning, I offer Takshak, along with Indra to the fire. Both Indra and Takshak began to descend towards the sacrificial fire.
Asteek asked Raja Janmejaya to stop the sacrifice and the yagna. Janmejaya having given his word to Asteek to ask anything had to keep his word and stop the Yagna. Asteek chanted mantras to slow the descent of Indra and Takshak. With the yagna called off, Takshak and Indra were thus saved.
The phrase “Indray Takshakay swaha” is used to remind us to be careful about the company we keep. The people we associate with can get us into trouble just like Indra was almost sacrificed because of his association with Takshak.