
108 Cal.App.2d 491 (1951)
THE PEOPLE, Respondent,
v.
PETER NEAL, Appellant.
Crim. No. 4684. 
California Court of Appeals. Second Dist., Div. Three.  
Dec. 28, 1951.
 Gladys Towles Root for Appellant.
 Edmund G. Brown, Attorney General, and Dan Kaufmann, Deputy Attorney General, for Respondent. *492
 WOOD (Parker), J.
 Defendant was charged in two counts with violation of section 288 of the Penal Code. It was alleged in the information that he had been convicted previously of violating said section. Trial by jury was waived. On June 10, 1949, he was convicted on both counts, and his request for permission to file an application for probation was granted. The date set for pronouncing judgment, for a hearing on the application for probation, and for "the determination of the prior conviction," was July 7, 1949.
 On said July 7th, the defendant appeared and filed his affidavit of sexual psychopathy; the court found that the allegation of a prior conviction was untrue, then pronounced judgment that the defendant be imprisoned in the state prison for the term prescribed by law as to each count, and suspended execution of the sentences. Trial by jury was waived as to the issue of sexual psychopathy. On said July 7th the hearing as to sexual psychopathy was had, and the court found the defendant to be a sexual psychopath. Proceedings were suspended and defendant was committed to the Director of Institutions for confinement in Norwalk State Hospital. No determination of defendant's application for probation was made, but the judge who was then presiding (Judge Barnes), signed a statement on the probation report that he had read and considered the report. Defendant was placed in Norwalk State Hospital on July 16, 1949.
 On March 21, 1951, defendant was returned to the superior court for further proceedings, under subdivision (b) of section 5517 of the Welfare and Institutions Code. A certificate, made by the hospital superintendent and approved by the director of the Department of Mental Hygiene, recited that the defendant had been treated to such an extent that, in their opinions, he "will not benefit by further care and treatment in the hospital, and is not a menace to the health and safety of others." In the letter, in which said certificate was sent to the court, the said director stated that he approved the recommendation of the hospital staff "that probation appears to be appropriate for this man." On that date defendant appeared without counsel, and the cause was continued to March 23, 1951. On said date defendant appeared with counsel (not his counsel on appeal), and the further proceedings were had before Judge Cunningham (who was not the judge who presided at the trial on the criminal charges and at the hearing on the issue of sexual psychopathy). Defendant's counsel presented arguments to the effect that *493 defendant should be released from custody. His counsel also stated that the record indicated that defendant had been rehabilitated, and he requested that the defendant be granted probation instead of being sent to the penitentiary. The judge stated, in effect, that he did not like to send the defendant to the penitentiary (he was 73 years of age) but, under the circumstances, it was his duty to do so. The minutes of the court recite that the court "pronounces judgment and sentence," and that the defendant is sentenced to the state prison for the term prescribed by law on each count, and is remanded to the custody of the sheriff to be delivered into the custody of the director of corrections. Thereafter on said March 23, 1951, a document entitled "Judgment" was signed by the judge which recited that the defendant had been found guilty, as charged in each count; and that it was ordered that defendant be imprisoned in the state prison for the term prescribed by law as to each count; and that he be remanded to the custody of the sheriff to be delivered to the custody of the director of corrections at San Quentin. No order was made granting or denying probation, and no order at all was made with respect to defendant's application for probation.
 The notice of appeal states that defendant appeals "from the judgment rendered on March 23, 1951, from the denial of motion for new trial made on March 23, 1951, and from all proceedings had herein up to and including March 23, 1951."
 It is to be noted that judgment was rendered on July 7, 1949, as to each of the two counts. The defendant did not appeal from those judgments and they became final in July, 1949 [1] Even though the execution of the sentences was suspended, the judgments were appealable. (See In re Phillips, 17 Cal.2d 55, 58 [109 P.2d 344, 132 A.L.R. 644].)
 The People assert that the purported appeal from the purported judgment of March 23, 1951, should be dismissed upon the ground that the purported judgment is merely a commitment and is not appealable.
 It seems that appellant also regards the purported judgment of March 23, 1951, as an order of commitment and does not consider it to be a judgment of conviction. Appellant contends, however, that said order (committing him to the penitentiary, after his return from the hospital) is appealable for the reason that it "was an order made after judgment" affecting the substantial rights of appellant. *494
 In support of that contention appellant argues that his application for probation, made on June 10, 1949, was not denied; that therefore it was still pending at the time sentences were pronounced on March 23, 1951; and that appellant was entitled to a full hearing on, and a determination of, such application. Section 1203 of the Penal Code provides, in part, that "if probation is not denied, and in every felony case in which the defendant is eligible for probation before any judgment is pronounced and whether or not an application for probation has been made, the court must immediately refer the matter to the probation officer to investigate and to report to the court at a specified time. ... At such time ... fixed by the court, the court must hear and determine such application and in connection therewith must consider any report of the probation officer, and must make a statement that it has considered such report which must be filed with the clerk of the court as a record in the case. If the court shall determine that there are circumstances in mitigation of punishment ... or that the ends of justice would be subserved by granting probation ... the court shall have the power in its discretion to place the defendant on probation. ..." (Italics added.) [2] It therefore appears that, while the granting of probation is a matter within the sound discretion of the trial court, it is mandatory that the court hear and determine the application for probation. As above shown, on the date set by Judge Barnes for hearing defendant's application for probation, namely, July 7, 1949, appellant was adjudged a sexual psychopath and was committed to the hospital, but no determination of his application for probation was made. Thereafter (March 23, 1951), during the proceedings before another judge (Judge Cunningham), after appellant's return from the hospital, appellant's counsel argued that defendant had been rehabilitated and that probation should be granted. Although the judge indicated that he would deny probation, he made no order denying probation. It does not appear that the judge made a statement that he had considered the report of the probation officer. Under the provisions of section 1203 of the Penal Code, such a statement must be made and filed with the clerk of the court. Defendant was entitled to have his application for probation heard and determined according to the provisions of said section 1203. As above shown, the allegation in the information regarding a prior conviction of a felony was found to be untrue. It does not appear that appellant is ineligible *495 for probation. [3] By reason of the failure of the judge to rule upon appellant's application for probation, the appellant was deprived of a substantial right. [4] The purported judgment rendered on March 23, 1951, is, in effect, an order of commitment under the circumstances herein where judgment had been pronounced previously and had become final. An order of commitment issued, under the circumstances herein, where the appellant's application for probation had not been ruled upon, is an order made after judgment affecting the substantial rights of appellant. Such a commitment is an appealable order within the contemplation of subdivision 3 of section 1237 of the Penal Code which provides that an appeal may be taken from "any order made after judgment, affecting the substantial rights of the party."
 [5] Appellant contends further that the court erred in not returning him to the jurisdiction of the Department of Mental Hygiene. He argues that the court was of the opinion that defendant still was a menace to the health and safety of others, and that under the provisions of section 5518 of the Welfare and Institutions Code the court had no alternative but to return him to the state hospital for further treatment. That contention is not sustainable. As above shown, defendant was returned from the state hospital to the superior court under subdivision (b) of section 5517 of the Welfare and Institutions Code. Section 5517 provides that when the superintendent of the hospital and the director of mental hygiene certify to the committing court their opinion, under subdivision (b) of said section 5517 (that the person committed will not benefit by further treatment and is not a menace to the health and safety of others), the said person shall be returned to the court "to await the further action of the court with reference to the criminal charge against him. The court shall resume the proceedings ... and after considering all the evidence before it may place the person on probation. ..." Said sections 5517 and 5518 were construed in the case of People v. Thompson, 102 Cal.App.2d 183 [227 P.2d 272]. When a defendant is returned to the court under subdivision (c) of section 5517 (for the reason that he has not recovered from sexual psychopathy and is still a menace to society), the provisions of section 5518 become applicable.
 Since there was no motion for a new trial, the purported appeal from an order denying said motion is dismissed. The purported appeal from all other proceedings is dismissed. *496
 The purported judgment or order of commitment of March 23, 1951, is vacated, and the cause is remanded to the superior court with instructions that the court consider and determine appellant's application for probation.
 Shinn, P. J., and Vallee, J., concurred.
