(the Crab) appears when the sun has reached his highest northern limit, and begins to go backward towards the south; but, like a crab, the return is sideways (June 21st to July 23rd). According to fable, Cancer was the animal which Juno sent against Hercules, when he combated the Hydra of Lernê. Cancer bit the hero's foot, but Hercules killed the creature,. and Juno took it up to heaven, and made it one of the twelve signs of the zodiac.
Source: Dictionary of Phrase and Fable, E. Cobham Brewer, 1894
More on Cancer from Fact Monster: