
184 Cal.App.3d 394 (1986)
229 Cal. Rptr. 74
THE STATE OF CALIFORNIA, Petitioner,
v.
THE SUPERIOR COURT OF SAN DIEGO COUNTY, Respondent; ST. MARY'S CATHOLIC CHURCH et al., Real Parties in Interest.
Docket No. D004709.
Court of Appeals of California, Fourth District, Division One.
August 12, 1986.
*395 COUNSEL
John K. Van de Kamp, Attorney General, Frederick R. Millar, Jr., and Rudolf Corona, Jr., Deputy Attorneys General, for Petitioner.
Lloyd M. Harmon, Jr., County Counsel, Daniel J. Wallace, Chief Deputy County Counsel, and Susan J. Boyle, Deputy County Counsel, for Respondent.
George H. Eiser III, City Attorney, Rosenberg & Fisch and Sanford M. Fisch for Real Parties in Interest.
*396 OPINION
WIENER, Acting P.J.
The office of the Attorney General, representing the State of California (State), seeks a writ of mandate or prohibition and a stay preventing the trial court from compelling the State to be joined as a defendant in this lawsuit.
Penal Code section 326.5 defines what constitutes a legal bingo game and makes it a misdemeanor to conduct bingo games except in accordance with the statute. St. Mary's Catholic Church (Church) and Selectro-Vision, Limited have brought a civil action against the City of National City (City) in the superior court, seeking declaratory relief and an injunction to prevent criminal prosecution of the Church's contemplated use of Selectro-Vision's electronic computer-controlled bingo system which permits playing 40 bingo cards simultaneously. Plaintiffs contend City has informed them the device is an illegal gambling device, based on two earlier opinions from the office of the Attorney General, and therefore the City will prosecute Church if it uses the device. (Those opinions are 66 Ops.Cal.Atty.Gen. 276 (1983) and 67 Ops.Cal.Atty.Gen. 528 (1984).)
At the suggestion of City, but without a formal joinder motion, the trial court ordered the State of California be joined as a defendant. The court also issued a temporary restraining order preventing City's prosecution of Church for use of the so-called "Bingo Master System." At the preliminary injunction hearing, the court denied the motion of the Attorney General on behalf of State to strike State as a party defendant. The court also issued a preliminary injunction.
State brings this writ petition, arguing the trial court has no power to compel its participation. It says the trial court made its ruling because interpretation of a state penal statute is involved and the office of the Attorney General has issued advisory opinions of some relevance to the issues. However, State says, these facts do not give it a substantial interest in the lawsuit so as to compel its unwilling participation. It points out the Attorney General is authorized and indeed obliged to issue advisory opinions to designated state and local officials (Gov. Code, § 12519), but those designated officials do not include superior court judges. Further, his opinions are only advisory and not binding in any event. (Gov. Code, § 12519, supra; Moore v. Panish (1982) 32 Cal.3d 535, 550-552 [186 Cal. Rptr. 475, 652 P.2d 32].) To compel participation of the Attorney General's office in every lawsuit where an opinion of the office might be relevant or where interpretation of a state penal law is involved would, State says, draw the office into innumerable lawsuits and would overwhelm its resources, undermining *397 its primary functions. Between 1979 and 1985, the office of the Attorney General has issued 723 official opinions.
Although we admit to have concerns with the validity of the underlying lawsuit, no one has asked us to remove the lawsuit from the court calendar. We are only concerned with the issue of removal of the State of California as an unwilling defendant. (1a) We believe the trial court has exceeded its discretion, if not its powers, in compelling the Attorney General's participation. Our decision to liberate the State here is influenced both by the lack of any specific authority for the court to order the State's participation and also by the doctrine of separation of powers.
(2) Starting with the question of authority for the court's order, we note the well-established rule a court may not issue its writ to control the discretion of a public officer. (See generally 8 Witkin, Cal. Procedure (3d ed. 1985) Extraordinary Writs, §§ 70, 80, pp. 709-710, 720-721; e.g., Larson v. City of Redondo Beach (1972) 27 Cal. App.3d 332, 337 [103 Cal. Rptr. 592].)
Put another way, a court cannot order a public officer to do something unless that officer has a plain duty to do it. (1b) Here, the office of the Attorney General has a general obligation to prepare advisory opinions but none to participate as advisor or amicus curiae, let alone defendant, in every lawsuit questioning the meaning of a state law. Accordingly, there is no basis for the court's order to the State to make itself available.
The doctrine of separation of powers, expressed in California Constitution, article III, section 3, holds one branch of our tripartite government may not exercise powers delegated to another coordinate branch. Here, the question is whether the judiciary may properly tell a department of the executive branch to join in a lawsuit. Such trespass upon the internal management and policy decisions of the Attorney General's office seems perilously close to the brink of unwarranted interference in violation of constitutional mandate.
(3) To give some examples of the separation of powers doctrine, we know, from State of South Dakota v. Brown (1978) 20 Cal.3d 765 [144 Cal. Rptr. 758, 576 P.2d 473], that the court may not compel the Governor to exercise discretion in the matter of extradition of fugitives. The power of pardon or commutation of sentence is likewise purely discretionary with the executive branch and not subject to legislative or judicial encroachment. (See discussion in Way v. Superior Court (1977) 74 Cal. App.3d 165, 176 [141 Cal. Rptr. 383].) It is also well established a court may not tell a district attorney whom to prosecute nor otherwise interfere with the charging function, *398 another purely executive power. (People v. Municipal Court (Pellegrino) (1972) 27 Cal. App.3d 193, 207 [103 Cal. Rptr. 645, 66 A.L.R.3d 717]; People v. Smith (1975) 53 Cal. App.3d 655 [126 Cal. Rptr. 195]; see discussion in People v. Superior Court (Greer) (1977) 19 Cal.3d 255, 262 et seq. [137 Cal. Rptr. 476, 561 P.2d 1164], permitting the court to disqualify a prosecutor but otherwise validating the exclusive executive control over the charging function.) The Greer case, supra, notes other prosecutorial decisions immune from court control: the district attorney may conduct a case in the manner he chooses, have the same control over trial tactics, within legal bounds, as any attorney, and negotiate a plea bargain. (People v. Superior Court (Greer), supra, at p. 267.) (1c) The decision of the Attorney General whether to participate in a lawsuit, where the State has no financial interest at stake nor possible liability, is a decision purely discretionary and, like decisions regarding the prosecution and conduct of criminal trials, exclusively within the province of the Attorney General's office and not subject to judicial coercion.
Because of the inevitable overlap of powers among the governmental branches, no easy way exists to determine the legitimacy of one branch's interference in another's domain. (See generally Laisne v. Cal. St. Bd. of Optometry (1942) 19 Cal.2d 831, 835 [123 P.2d 457].) We decline to hold a court may never under any circumstances draw an unwilling governmental officer into a lawsuit, but this is not such a case. The showing made of the Attorney General's expertise as to the meaning of the term "bingo" in Penal Code section 326.5 is not enough to compel him to defend the suit.
An alternative writ or order to show cause would add nothing to the presentation. A peremptory writ is proper. (Code Civ. Proc., § 1088; United Nuclear Corp. v. Superior Court (1980) 113 Cal. App.3d 359 [169 Cal. Rptr. 827]; Goodenough v. Superior Court (1971) 18 Cal. App.3d 692, 697 [96 Cal. Rptr. 165].)
Let a writ of mandate issue compelling the trial court to grant the Attorney General's motion to strike the State of California as a party defendant.
Work, J., and Butler, J., concurred.
