To be effective, it was vital that the men kept formation. The power of the pike came from the
mass of numbers, rather than the weapon itself. Men would be pressed shoulder to shoulder when
advancing, so that there were no weaknesses in the line.
Against cavalry, the first rank would set their pikes at roughly 50 degrees to the ground, with the end against the instep of their foot, firmly set in the ground. The second rank would often hold their pikes horizontally at shoulder height, to give a double blow to any horse that came too close.
Against infantry, the first two or three ranks would all hold their pikes horizontally. They would then advance, jabbing until contact was made. If contact was reached, then push of pike began. The pikemen would try to injure or kill as they advanced, but then there would be no room to manouever the long weapons, so the front ranks would crash into each other, and a pushing contest would develop. Melee weapons might be used, but with the weight of rear ranks pressing against them, these would quickly become useless, and the battle would be decided by which side could push the other back physically.
The real carnage came if one side broke and collapsed or ran, leaving them open to attack from behind by the victors.