concurring in part and dissenting in part:
It is axiomatic that this court upon review of a case will search the record to affirm and will affirm a trial court when it reached the right result but perhaps for an erroneous reason. In this case, the trial court predicated its dismissal upon a jeopardy question. I would agree that under the case law jeopardy is not a basis for the result.
However, this court in In re R. L. K. (1978), 67 Ill. App. 3d 451, 384 N.E.2d 531, held the compulsory joinder statute of the Criminal Code of 1961 applicable to juvenile proceedings. The opening paragraph of the opinion of Mr. Justice Mills was: “Are the concepts of double jeopardy and compulsory joinder to be applied to MINS proceedings (minor in need of supervision)? The short answer: Yes.” (67 Ill. App. 3d 451, 452, 384 N.E.2d 531, 532.) Thus, under that opinion, and People v. Pohl (1964), 47 Ill. App. 2d 232, 197 N.E.2d 759, and People v. Bressette (1970), 124 Ill. App. 2d 469, 259 N.E.2d 592, at most we would be required here to remand to ascertain whether the prosecutor had knowledge of both offenses at the time of the plea of guilty to the offense of driving without a license. If so, the trial court reached the right result and an ultimate judgment of affirmance should be entered by this court. Thus, I would remand for that limited purpose and proceed thereafter based upon the evidence thus developed.