law: 3. Power of courts to require appearance of prisoners to give evidence or answer a charge.-
  (1) Any civil or criminal court may, if it thinks that the evidence of any person confined in any prison is material in any matter pending before it, make an order in the form set forth in the First Schedule, directed to the officer in charge of the prison: Provided that no civil court shall make an order under this sub-section in respect of a person confined in a prison situated outside the State in which the court is held.
  (2) Any criminal court may, if a charge of an offence against a person confined in any prison is made or pending before it, make an order in the form set forth in the Second Schedule, directed to the officer in charge of the prison.
  (3) No order made under this section by a civil court which is subordinate to a district judge shall have effect unless it is countersigned by the district judge; and no order made under this section by a criminal court which is inferior to the court of a magistrate of the first class shall have effect unless it is countersigned by the district magistrate to whom that court is subordinate or within the local limits of whose jurisdiction that court is situate.
  (4) For the purposes of sub-section (3), a court of small causes outside a presidency town or the city of Hyderabad shall be deemed to be subordinate to the district judge within the local limits of whose jurisdiction such court is situate.