
175 Cal.App.3d 267 (1985)
220 Cal. Rptr. 893
WILLIE WISELY, Petitioner,
v.
THE SUPERIOR COURT OF ORANGE COUNTY, Respondent; THE PEOPLE, Real Party in Interest.
Docket No. G003334.
Court of Appeals of California, Fourth District, Division Three.
November 25, 1985.
*268 COUNSEL
Willie Wisely, in pro. per., for Petitioner.
No appearance for Respondent.
John K. Van de Kamp, Attorney General, and Keith I. Motley, Deputy Attorney General, for Real Party in Interest.
OPINION
TROTTER, P.J.
Petitioner is the defendant and represents himself in a death penalty case. In a first trial, he was found guilty, given a penalty advisory verdict of death, and the trial judge granted a new trial on the penalty phase. The People have appealed the new trial order, and their appeal is presently before this court in case No. G000749.
*269 Petitioner has attempted to proceed with discovery in preparation for the new trial on the penalty phase. In two separate rulings (one on Aug. 2, 1985 by Judge William Thomson, and one on Aug. 23, 1985 by Judge Ronald E. Owen) the People's motions to quash petitioner's subpoenas duces tecum were granted and petitioner's motion to compel production of probation reports pursuant to Penal Code section 1203.05 was denied. The stated ground for each of the orders is that the matter is stayed pending the People's appeal from the order granting new trial, and the superior court lacks jurisdiction to enforce the subpoenas and to grant an order to compel production.
We conclude the trial court had jurisdiction with respect to petitioner's discovery requests and that the trial court erred in refusing to exercise its discretion on the merits.
(1) Code of Civil Procedure section 916 provides in pertinent part: "(a) Except as provided in Section 917.1 through 917.9 and in Section 117.7 [none of which are applicable here], the perfecting of an appeal stays proceedings in the trial court upon the judgment or order appealed from or upon the matters embraced therein or affected thereby, including enforcement of the judgment or order, but the trial court may proceed upon any other matter embraced in the action and not affected by the judgment or order." (Italics added.)
In People v. Castro (1982) 138 Cal. App.3d 30, at page 32 [187 Cal. Rptr. 658], the court stated: "Even after an appellate court has obtained jurisdiction over a dispute, `[t]he trial judge retains certain powers over the parties and the incidental aspects of the cause which are not within the scope of the reviewing court's exclusive jurisdiction. [Citation.] ...'" In Hays v. Superior Court (1940) 16 Cal.2d 260 [105 P.2d 975] the court acknowledged the trial court's jurisdiction to rule on a motion that a witness comply with the taking of her deposition despite the fact that the case was on appeal after a judgment of dismissal had been entered.
In Echavarria v. Superior Court (1979) 94 Cal. App.3d 467 [156 Cal. Rptr. 527] the defendant, who was charged with murder, had been found to be incompetent to stand trial and was committed to a state hospital until she regained capacity. Her attorney sought appointment of a psychiatrist to determine whether she should rely on a defense of not guilty by reason of insanity when and if she was able to stand trial. The trial court refused the request, taking the position that it lacked jurisdiction because Penal Code section 1370 provided, in part, as follows: "If the defendant is found mentally incompetent, the trial or judgment shall be suspended until he becomes mentally competent...." (Italics added.) The appellate court *270 held the trial court did have jurisdiction, stating: "We see nothing in that provision to bar the court from entertaining and acting on a request for the relief here sought. (2) Inevitably, discovery proceedings, of all varieties, must precede a trial; even an appeal from a judgment does not prevent the carrying on of discovery proceedings. [Citations.]" (Echavarria v. Superior Court, supra, 94 Cal. App.3d at pp. 469-470.) We hold the reasoning of Echavarria is applicable here. Petitioner has a right to participate in discovery prior to his new trial on the penalty phase.[1] (See People v. Memro (1985) 38 Cal.3d 658, 677 [214 Cal. Rptr. 832, 700 P.2d 446].) To hold he was not entitled to exercise that right pending an appeal by the People would have a distinctly adverse effect on petitioner's fundamental right to a fair trial.
We hold discovery proceedings sought preparatory to an anticipated new trial on the penalty phase constitute matters embraced in the action and not affected by the judgment or order, within the meaning of Code of Civil Procedure section 916. (3) "Mandamus is the proper remedy to compel a court to assume or exercise jurisdiction ... where it has jurisdiction and has refused to proceed on the ground of lack of jurisdiction. [Citations.]" (Italics in original.) (Austin v. Turrentine (1939) 30 Cal. App.2d 750, 759-760 [87 P.2d 72].)
Let a peremptory writ of mandate issue (Palma v. U.S. Industrial Fasteners, Inc. (1984) 36 Cal.3d 171, 182 [203 Cal. Rptr. 626, 681 P.2d 893]) directing respondent superior court to annul its orders of August 2, 1985 and August 23, 1985, granting real party in interest's motions to quash petitioner's subpoenas duces tecum and denying petitioner's motion to compel production of probation reports under Penal Code section 1203.05, and to hear the motions on their merits.
Sonenshine, J., and Wallin, J., concurred.
Petitioner's application for review by the Supreme Court was denied January 15, 1986.
NOTES
[1]  We do not intend to indicate any determination on the merits of petitioner's discovery requests.
