To understand why Jesus took such violent action in the Temple precincts, we have to take a look at a bit of background first.
At the time, the Temple of Jerusalem stood in a commanding position on the top of Mount Moriah and dominated the rest of the city .
Previously, in about 20 B.C. an ambitious rebuilding of the Temple was undertaken by Herod the Great to restore it to its original Solomonic glory. He enlarged its precincts which were surrounded by retaining walls of incomparable workmanship and great height. Just inside the walls were great colonnades or porticoes, the most notable of which was Solomon’s Portico (where Jesus sometimes taught – John 10 V.23).
In the Court of the Gentiles (or Outer Court), despite the sanctity of the Temple area, there was a flourishing trade in sacrificial animals. There were shops where pilgrims who had come up to Jerusalem to worship in the Temple could buy oxen, sheep and doves, which could then be offered up in the appropriate sacrifices.
There were tables where money-changers changed money for the payment of the annual Temple tax. Most of the currency circulating in Judea was Roman money but as such coins bore a portrait of the Emperor, it was generally considered unacceptable for sacrificial offerings because it was in violation of the second commandment. So the Roman coins had to be changed into a special coinage which was the only legal fare for Temple dues or sacrifices. This profitable trade, which was supported by the powerful high priestly family of Annas and Caiaphas, was being held in the Temple precincts for the first time. Caiaphas, the High Priest, had also introduced the sale of animals in the Temple forecourt which gave him great financial gain but turned the forecourt into little more than a cattle market.
It was this commercial use of the Court of the Gentiles which prompted Jesus to take firm action as he felt, quite rightly, that this was a shocking misuse of the Temple area.