Earlier this month, the state had witnessed massive protests after the High Court ordered that a little-known law passed in 1932, banning cow slaughter and the sale of beef in the state, be strictly enforced.
Mr Sharma, the government had said, had failed to represent it adequately in court. Exactly a week ago, he was shifted to the education department.
"I was sacked to please some elements in Kashmir who are openly defying the ban," Mr Sharma told NDTV.
Mr Seth had filed the petition in court last year as a lawyer and he had pursued it even after being appointed the deputy advocate general six months ago.
Sources say the government had asked him to withdraw the petition or face action, but the leaders of the BJP, an ally of the ruling PDP, came out openly in favour of the ban.
"The law department was pressurising me to withdraw the petition but I refused to withdraw it since it was just about implementation of law," said Mr Seth.
Today's action comes days ahead of the Bakar Eid, during which, various political and religious groups of the Kashmir Valley have said they would defy the ban and undertake mass slaughter of cattle. Animal sacrifice is a traditional part of the festival.
The opposition National Conference and two other parties have said they would introduce three bills in the state assembly to amend the 1932 law. The BJP has said they will not allow introduction of the bills.