
341 So.2d 214 (1976)
Jerry Lee WILLIAMS, Appellant,
v.
STATE of Florida, Appellee.
No. 76-171.
District Court of Appeal of Florida, Second District.
December 17, 1976.
Rehearing Denied January 19, 1977.
*215 Jack O. Johnson, Public Defender, Robert H. Grizzard, II, Asst. Public Defender, and Paul J. Martin, Legal Intern, Bartow, for appellant.
Robert L. Shevin, Atty. Gen., Tallahassee, and William I. Munsey, Jr., Asst. Atty. Gen., Tampa, for appellee.
BOARDMAN, Judge.
Appellant/defendant pled guilty to aggravated assault in violation of Section 784.04, Florida Statutes (1973). At the hearing following the court's colloquy with appellant establishing the voluntariness and the factual basis for acceptance of the plea the trial judge, the Honorable Harry Lee Coe, said he would withhold adjudication and defer sentence from "day to day and term to term." The judge advised appellant that if he sincerely and honestly assisted the police as an informant that he would "get rid of the case entirely."[1] The judge reserved the right to sentence appellant to five years imprisonment if he did not cooperate in good faith or if he were convicted of another crime during the period the sentence was deferred.
Prior to a hearing on appellant's performance of the agreement Judge Coe recused himself, and the case was assigned to the Honorable Herboth S. Ryder. Judge Ryder correctly found that the deferred sentence was invalid and further that the agreement fashioned by Judge Coe was "unconstitutional." Appellant's guilty plea was withdrawn, and the case was set for trial. At a pretrial hearing held on the day of the trial evidence of appellant's good faith performance of his end of the bargain was presented to Judge Ryder, and he found that appellant had satisfied the plea bargain and that in the interest of fairness and justice he would place appellant on probation for five years. At this juncture appellant pled guilty again but during the colloquy Judge Ryder determined that appellant had a valid defense to the charge, i.e. self-defense. The judge set aside appellant's guilty plea and entered a plea of not guilty. Appellant was found guilty at the *216 conclusion of a jury trial, and Judge Ryder sentenced him to five years imprisonment.[2]
We are aware that upon vacation of an order which defers sentencing from "day to day and term to term" a defendant is amenable to imposition of a term of imprisonment. See State v. Bateh, 110 So.2d 7 (Fla. 1959). Nevertheless we have no difficulty in reaching the conclusion that appellant was prejudiced by the turn of events in this case, and under these peculiar circumstances a probationary term rather than a term of imprisonment should be imposed consistent with the plea bargain. Appellant did not complain that the plea bargain was "unconstitutional," and despite the invalidity of the sentence he had a right to specific performance of that bargain because as Judge Ryder found he had affirmatively complied with a court-sanctioned bargain. This court has previously held that a court-approved agreement was specifically enforceable if, as in this case, the accused satisfied the conditions of the agreement. State v. Davis, 188 So.2d 24 (Fla.2d DCA 1966). See also Butler v. State, 228 So.2d 421 (Fla.4th DCA 1969). The case before us is significantly different from a situation where specific performance of a plea bargain would not be required. See Barker v. State, 259 So.2d 200 (Fla.2d DCA 1972). In Barker the court tentatively agreed to a plea bargain, the defendant did not change his position by acting upon the bargain, and the court subsequently became aware of facts indicating that leniency was not appropriate.
Accordingly the judgment and sentence is reversed, and the cause is remanded for proceedings consistent with this opinion.
REVERSED and REMANDED.
McNULTY, C.J., and SCHEB, J., concur.
NOTES
[1]  It is not clear what Judge Coe meant by "get rid of the case," but he probably intended to place appellant on probation at a later time if appellant performed adequately as an informant.
[2]  The maximum sentence for aggravated assault was five years. §§ 775.082(4)(d), 784.04, Fla. Stat. (1973).
