Megasthenes, the Greek ambassador to Chandragupta Maurya's court, referred to Krishna/Vishnu as 'Heracles' in his work 'Indica'. This Greek equivalence was common as they mapped Indian deities to their own pantheon's gods. Shiva was sometimes linked to Dionysus, not Vishnu.