This writ is issued by a higher court to a lower court or tribunal or quasi-judicial authority either to transfer a case pending with the latter to itself or to quash the order of the latter in a case. It is issued on the grounds of excess of jurisdiction, lack of jurisdiction, or error of law.