
53 Cal.App.4th 1333 (1997)
THE PEOPLE, Petitioner,
v.
THE SUPERIOR COURT OF LOS ANGELES COUNTY, Respondent; ANTHONY EDWARD GIFFORD, Real Party in Interest.
Docket No. B106633.
Court of Appeals of California, Second District, Division Two.
March 28, 1997.
*1334 COUNSEL
Gil Garcetti, District Attorney, Brent Riggs and Moira J. Curry, Deputy District Attorneys, for Petitioner.
No appearance for Respondent.
Stephen I. Blanchfill, under appointment by the Court of Appeal, for Real Party in Interest.
*1335 OPINION
NOTT, J.
The People seek a writ of mandate directing the superior court to set aside its order of August 29, 1996, granting real party, Anthony Edward Gifford, a probationary sentence after his conviction for violation of Penal Code[1] section 12303.3, possession of an explosive device. The primary question presented is this: Is a sentencing court vested with the discretion to alter the terms of a negotiated plea by imposing a probationary sentence rather than a prison term? Our answer is: No.

I. FACTUAL AND PROCEDURAL BACKGROUND
A felony information was filed charging Gifford with two counts of using an explosive device in violation of section 12303.3. It was further alleged that probation was prohibited pursuant to section 12311.[2]
Later, the prosecutor and Gifford's attorney negotiated a plea agreement in which Gifford agreed to plead guilty to count 1 for a "low term lock," i.e., three years in state prison, in exchange for a dismissal of count 2. The agreement did not include the grant of probation.
Gifford entered a plea of guilty to count 1 of the information, a violation of section 12303.3. He initialed and signed a form entitled, "Guilty Plea in the Superior Court," which reflects that he read, understood, and waived his constitutional rights in order to enter his guilty plea. The form provides as follows: "My lawyer has told me that if I plead guilty to the above charge(s)... the court will sentence me as follows: [¶] Other: I will be sentenced to the low term of 3 years in the state prison."
During the plea hearing, the prosecutor verified the terms of the plea, and Gifford agreed to the bargain. After the prosecutor informed Gifford of his constitutional rights, Gifford stated he understood his rights and wished to give them up in order to plead guilty. The prosecutor informed Gifford of the consequences of his plea. Gifford then pled guilty to count 1, a violation of section 12303.3, and admitted that on November 9, 1995, he exploded an explosive device. The superior court accepted the plea, and set the matter for sentencing.
*1336 During the sentencing hearing, the court advised the parties that it had read and considered People v. Tritchler[*] (Cal. App.) (Tritchler), a case which had been published following the court's approval of the negotiated plea.[3] The court opined that Tritchler vested the court with the discretion to alter the terms of the plea bargain and impose a probationary sentence rather than a prison term  provided the court determined that under the facts of the case imposition of a prison term would constitute cruel and unusual punishment. After hearing argument from the parties, and considering a diagnostic report received pursuant to section 1203.03, and letters filed in support of Gifford, the court granted Gifford probation, subject to certain conditions. The prosecutor objected to the grant of probation. This petition for writ of mandate followed.

II. DISCUSSION

A. Writ Review

Section 1238, subdivision (d) provides: "Nothing contained in this section shall be construed to authorize an appeal from an order granting probation. Instead, the people may seek appellate review of any grant of probation, whether or not the court imposes sentence, by means of a petition for a writ of mandate or prohibition which is filed within 60 days after probation is granted. The review of any grant of probation shall include review of any order underlying the grant of probation." The People filed this writ petition within 60 days after the order granting probation was entered. Writ review is, therefore, proper.

B. Contentions

(1a) The People contend that the superior court was "without jurisdiction to impose a probationary sentence contrary to ... section 12311," and the court "acted in excess of its jurisdiction in ruling that [Tritchler] conferred upon it the discretion to grant probation" to Gifford.
Gifford contends that because it was mistakenly assumed  at the time the plea bargain was accepted by the court during the plea hearing  that section 12311 prohibited a probationary sentence, the sentencing court retained discretion, pursuant to Tritchler, to alter the terms of the negotiated plea and impose a probationary sentence  provided the court determined that a prison sentence under the facts of this case would constitute cruel and unusual punishment.


*1337 C. Tritchler

In Tritchler, supra, D021748, a jury convicted two defendants of possession of a destructive device (§ 12303), possession of a destructive device or explosive on a public street or near private habitation (§ 12303.2), and transportation of a destructive device (§ 12303.6), arising out of an incident in which they threw a homemade explosive device at another car.[4] The jury also found one of the defendants guilty of possessing and exploding or igniting a destructive device or explosive (§ 12303.3.) The trial court refused to grant probation, on the basis that a prison term was mandatory pursuant to section 12311. On appeal, the convictions were affirmed. The sentences, however, were vacated and the case remanded to allow the court, in its discretion, to grant probation to the defendants. The appellate court determined that under the circumstances of the case imposition of a mandatory prison term was "grossly out of all proportion to the offenses committed." The court also concluded that "[d]enial of probation in this case shocks the conscience and offends fundamental notions of human dignity."
The Tritchler court, upon examination of facts (which had been fully developed during trial), held that under certain circumstances a mandatory prison term imposed under section 12311 may constitute cruel and unusual punishment.[5] Nothing contained in Tritchler authorizes a court reviewing a negotiated plea to alter the terms of a plea agreement.

D. Alteration of the Terms of the Plea Bargain.

(2) "The imposition of sentence and exercise of discretion are fundamentally and inherently judicial functions. [Citation.] While no bargain or agreement can divest the court of the sentencing discretion it inherently possesses [citations], a judge who has accepted a plea bargain is bound to impose a sentence within the limits of that bargain. [Citation.] `A plea agreement is, in essence, a contract between the defendant and the prosecutor to which the court consents to be bound.' [Citations.] Should the court consider the plea bargain to be unacceptable, its remedy is to reject it, not to violate it, directly or indirectly. [Citation.] Once the court has accepted the terms of the negotiated plea, `[it] lacks jurisdiction to alter the terms of a plea bargain so that it becomes more favorable to a defendant unless, of course, the parties agree.' [Citation.]" (People v. Ames (1989) 213 Cal. App.3d 1214, 1217 [261 Cal. Rptr. 911].)
(1b) Here, the prosecution agreed to dismiss one of two counts, in exchange for which Gifford agreed to plead guilty to possession of an *1338 explosive device and to be sentenced to three years in state prison. During the plea hearing, the court accepted these terms. It therefore lacked jurisdiction to alter the terms of the plea bargain so that it became more favorable to Gifford. (People v. Ames, supra, 213 Cal. App.3d at p. 1217.)

E. Judicial Withdrawal of Plea Approval

We do not mean to suggest that the court was without authority  following the plea hearing, but prior to imposing sentence  to withdraw its approval of the negotiated plea. Such withdrawal is statutorily sanctioned by section 1192.5. (People v. Stringham (1988) 206 Cal. App.3d 184, 194 [253 Cal. Rptr. 484].)
Section 1192.5 provides in pertinent part: "Where the plea [of guilty] is accepted by the prosecuting attorney in open court and is approved by the court, the defendant, except as otherwise provided in this section, cannot be sentenced on the plea to a punishment more severe than that specified in the plea and the court may not proceed as to the plea other than as specified in the plea.
"If the court approves of the plea, it shall inform the defendant prior to the making of the plea that (1) its approval is not binding, (2) it may, at the time set for the hearing on the application for probation or pronouncement of judgment, withdraw its approval in the light of further consideration of the matter, and (3) in that case, the defendant shall be permitted to withdraw his ... plea if he ... desires to do so....
"If the plea is not accepted by the prosecuting attorney and approved by the court, the plea shall be deemed withdrawn and the defendant may then enter the plea or pleas as would otherwise have been available."
"[I]mplicit in the language of section 1192.5 is the premise that the court, upon sentencing, has broad discretion to withdraw its prior approval of a negotiated plea." (People v. Johnson (1974) 10 Cal.3d 868, 873 [112 Cal. Rptr. 556, 519 P.2d 604].) Such withdrawal is permitted, for example, in those instances where the court becomes more fully informed about the case (People v. King (1981) 123 Cal. App.3d 406, 408 [176 Cal. Rptr. 507]), or where, after further consideration, the court concludes that the bargain is not in the best interests of society. (People v. Woodard (1982) 131 Cal. App.3d 107, 110 [182 Cal. Rptr. 254].)
Here, the court approved of the proposed plea bargain after being provided with the probation report and the preliminary hearing transcripts. After *1339 the plea hearing, the court reviewed letters written in support of Gifford, and a diagnostic report received pursuant to section 1203.03. Upon becoming more fully informed about the case, the court concluded that the aspect of the bargain which called for a three-year prison term was not in the best interests of society. The court was permitted, at that point, to withdraw its approval of the bargain. (People v. Stringham, supra, 206 Cal. App.3d at p. 196.)[6]
Had the court followed the proper procedure, and simply withdrawn its approval of the plea bargain (rather than erroneously altering the terms of the agreement), the plea (in light of the prosecutor's objection to the probationary sentence) would have been deemed withdrawn. Gifford would then have been permitted "to enter the plea or pleas as would otherwise have been available." (§ 1192.5.)

III. DISPOSITION
Let a peremptory writ of mandate issue directing the respondent court to vacate its order of August 29, 1996, imposing a probationary sentence, and to issue a new and different order consistent with this opinion. In other words, the court may approve the plea agreement as negotiated by the parties, or, the court may, in accordance with section 1192.5, exercise its discretion to withdraw its prior approval of the plea. The temporary stay is vacated.
Boren, P.J., and Zebrowski, J., concurred.
NOTES
[1]  All further statutory references are to the Penal Code unless otherwise indicated.
[2]  Section 12311 provides as follows: "No person convicted of a violation of this chapter shall be granted probation, and the execution of the sentence imposed upon such person shall not be suspended by the court."
[*]   Reporter's Note: Review denied November 20, 1996, and opinion (D021748) deleted upon direction of Supreme Court.
[3]  The order directing that Tritchler not be published was issued after this petition was filed.
[4]  We cite Tritchler under California Rules of Court, rule 977(b).
[5]  We express no opinion as to the validity of the court's conclusion.
[6]  Upon remand, the court will be required to either approve the plea as negotiated, or withdraw its approval of the plea. Should the court exercise its broad discretion and decide to withdraw its approval, it will undoubtedly state its reasons for doing so. Should the prosecution be dissatisfied with the court's decision, its remedy is to seek a petition for writ of mandate on the ground that the court abused its discretion in withdrawing its approval of the plea.
