In hollywood movies or most notably Game of Thrones, most soldiers carry swords. As far as I know, this is incorrect and Pikes were the most used weapon since it was so easy to manufactore and to train. Please correct me if I am wrong.
But why do movies and series always use swords as the main weapon if it was in reality the Pike?
And as far as I know, heavy cavalry, as in heavily armored knights, where the main striking force in the Medieval Age, flanking the enemy and striking a fatal blow to win the battle. But if the pike was so prominant, why did european armies still relied so heavily on their knights to win the fight, or rather: Why was the cavalry able to do this, if atleast 1/2 of the enemy army was equipped with pikes that basically rendered cavalry useless?
Are you specifically talking about pikes or polearms in general?
Hiya!! Not at my computer right now, so sources will be delayed and apologies for formatting. I can't do a well-informed media critique, but let's talk a little bit about medieval warfare. I don't want to say you are incorrect, but you are oversimplifying things heavily.
To start with I don't really know how you would quantify what the most commonly used weapon was. Some other commenters have mentioned the variety of polearms during the period, a pike being a fairly specific one in a broader category. While polearms are are in principle cheaper and easier to make, by the late Middle Ages, a sword wouldn't be prohibitively expensive, especially for a nobleman or someone who is spending extensive time soldiering. There are also advantages to a sword. Depending on the design and length, a sword could be used within arms length, with both slashing and thrusting maneuvers. The weighted pommel could be used in a hammering motion and the steel bar could act as a staff for blocking if a halfswording technique was employed. A greatsword could be gripped with both hands and employed like a polearm.
Secondly, these things are not mutually exclusive, you may ride into combat with a lance or start in a pike formation, but keep additional weapons in case. If you are risking your life/army in battle, you would likely not keep a single weapon just for the symbolism, but try to employ all options to give the most adaptability to combat. Swords work well for the aforementioned flexibility, as well as the ease of carrying one in your belt. But you would also see daggers or hammers as well. Pikes and lances are great weapons in particular situations, but can break, or become unwieldy depending on how close the enemy is or how much mobility the conflict requires. Carrying around a 20 foot spear in tight formation was no easy task!!
I guess this gets to the final point, which is that weapons have different uses in different situations, but in a pitched battle, tactical flexibility was still incredibly important. It is a huge exaggeration to say that soldiers armed with pikes render cavalry useless. A well disciplined and ordered pike formation on even ground can repulse a cavalry charge would be more accurate. But even then, what if the cavalry refuses to give battle and raids you villages 10 miles away? Have fun keeping lugging those sticks around on foot trying to keep up with a mounted force. Even if they give battle, a massed formation wasn't invulnerable. Missile fire could disrupt the morale and order of the formation as happened at falkirk with welsh archers softening Scottish pike formations before the main force charged. If pikemen become fixed in position due to Melee with enemy infantry, they will have a harder time wheeling their formation or forming squares to repulse a flanking charge.
The takeaway here is that apart from symbolism, prominence of weapons wasn't really that decisive in battles. This is why in the high and late Middle Ages you see the development of combined arms systems, employing simple fortifications, projectile fire, cavalry and infantry. Commanders would then add their own wrinkles, such as mounted infantry (riding to battle, but fighting on foot), chevaunchee, and Fabian tactics. There simply wasn't a decisive or definitively favored weapon, even the onset of gunpowder took a long time to cause a military revolution in pitched battles.
Hope this helps and let me know if you have follow ups (lunch is over so they will have to wait till this evening). Hopefully someone else can do a media critique for you too!!
EDITS (grammar and readability above):
A couple of additional points that I should have originally included but didn't have time (plus I think some relevant comments in this discussion have been removed, so I wanted to reiterate those ideas as well) and then sources.
Pikes fall under a larger category known as polearms which is not a very well-defined category, pretty much "a stick with a piece of metal on the end." Pikes specifically (generally a 15-25 foot polearm), were a fairly late development in the medieval period, reflecting the rise of infantry as a major force in pitched battles. They really only hit their stride in terms of use in the early modern period after the middle ages are generally considered over, but more on that in a moment. Pikes, in short, created a very powerful defensive formation if properly deployed and handled by disciplined soldiers. This was no easy task, think of how terrifying to face down hundreds of horse galloping toward you with men encased in armor pointing sharp objects at you. But the strength of the formation also relies on its mass, the soldiers have to act cohesively to be successful. This required a good amount of training to effectively understand how to position yourself and your weapon in the formation as well as adapt to the stress of combat. In addition, there needs to be a certain degree of uniformity in equipment for a pike formation to work. Early on, at the Battle of Golden Spurs or Bannockburn, these pike formations were more or less fixed in place, making them great defensively. However, mobility both on a strategic and tactical level was an issue. Moreover, the organizational level to successfully prepare pike formations was often beyond many medieval political entities.
In truth, pike formations really only came into there own during the Burgundian and Italian Wars during the early modern period. At this point, there were some polities, specifically cities in the low countries, Italian City-States, and Swiss Cantons, that had significant enough organization to develop regularized pike militias, with quality equipment and training. This led to the development of the famous Swiss mercenaries, who were not only capable of fighting in fixed positions, but were capable of incredible degrees of maneuver, as demonstrated at Grandson and Nancy where they defeated Charles the Bold. These infantrymen could also charge other positions. Eventually, other political entities began to adopt and develop their own pikemen. Machievelli, for example, was very peeved that Louis XI gave up on developing is own standing army skill in favor of simply paying for Swiss mercenaries. The combination of these troops with firearms led to the Spanish tercio. However, this still required combined arms and tactical flexibility (as well as quality equipment and training). Once pike formations were fixed in a "push of pike," troops with closer range weapons, such as swords or halberds could try to sneak past the pikes to break the formation, or projectile/firearms could break the formation. There was no definitive "weapons" advantage. Hope all this helps!
Sources:
Arms, Armies and Fortifications in the Hundred Years War edited by Anne Curry and Michael Hughes, 1994
Medieval Warfare: A History by Maurice Keen, 1999
A History of Warfare by John Keegan, 1993
The Renaissance at War by Thomas Arnold, 2006
Nobles, Knights, and Men-at-Arms in the Middle Ages by Maurice Keen, 1996