What was the earliest use of Cavalry in battle and what was it used for?
Cavalry developed from the chariot. The first domesticated horses, bred for meat, lacked the size and the strength in their front legs to be ridden from a forward 'control' position (as horses are ridden today). They were, however, by about 1700 BC, capable of pulling small loads. Although there are depictions of Sumerian kings going into battle on wagons pulled by onagers, onagers, asses and oxen proved physically unsuitable and too difficult to control for military use. The horse posed its own problems--it had no prominent shoulders, and could not be fitted with a simple yoke or a neck band for the purposes of pulling loads. The more complicated combination of bit and padded collar had yet to be developed. This meant that to take advantage of the speed and agility of the horse any vehicle had to be extremely light. Chariots weighed in general only about 75 lbs. The first charioteers probably appeared in the border regions surrounding the 'civilised' lands of Mesopotamia, Egypt and the Indus Valley, used by pastoralists who could use the new invention for herding and due to their experience of unsentimental killing and herd management were able to utilise the chariot to its full military potential. Battle tactics tended to be indirect, involving encirclement and harassment with the bow, and withdrawal from any attempt to draw the charioteers into combat. The ultimate objective was to wear down the enemy, break his ranks and allow him to be dispersed. This laid the foundation for cavalry tactics used by most horse nations right up until the Mongols in the 13th century--heavy shock cavalry were really the exception compared to such 'skirmishing' cavalry.
The chariot probably spread very quickly, both due to its obvious prestige value and the light, easily transportable and easily replicated nature of the design, with the main limitation on its use being access to sufficient numbers of horses. These had to be properly trained, and we see the first indications of specifically trained 'cavalry' horses in Mesopotamia in 12-1300 BC.
The replacement of the horse and chariot with the horse alone probably took place around 6-700 BC--it is hard to specify an exact date since horses had been ridden since at least 1350 BC, but not in the modern style. Due to the weakness of the horse riders instead had to sit above its back legs, a position which did not allow for precise control or the use of weaponry. It took until c.800 BC for a horse to be produced in Assyria which was capable of taking the weight of a rider in the 'control' position, and this technique seems to have spread to the periphery of the empire and again been taken up by pastoralists, the Cimmerians and Scythians, who invaded Assyria and had defeated her by 605 BC. The chariot, however, remained extremely prominent as a symbol of prestige--Persian king Darius famously led at the battle of Gaugamela from his chariot, so it is ironic that Alexander the Great's newer cavalry played such a crucial role in his defeat. Although Alexander's cavalry were firmly in the 'shock' role--they played the hammer to his pikemen's anvil--I'd argue that generally the employment of cavalry differed little from the use that had been found for the chariot--a mobile platform for missile weaponry. Cavalry is summed up nicely by John Keegan as 'charioteering without the chariot'. It was the indirect, harassing tactics of the chariot armies which would also define the horse peoples who carried out 'what was to be a repetitive cycle of raiding, despoilation, slave-taking, killing and, sometimes, conquest that was to afflict the outer edge of civilisation--in the Middle East, in India, in China and in Europe--for 2000 years.'
Source: John Keegan, A History of Warfare (London, Random House, 1993).