Defendant was convicted of violating sec. 939.32 (1), Stats., by attempting to violate sec. 944.01 (1). Sec. 959.15, sometimes referred to as the sex-deviate law, provides in part:
*194 “(1) If a person is convicted under . . . section 939.32 for attempting to violate section 944.01 . . . the court shall commit him to the state department of public welfare for a presentence social, physical, and mental examination.” The municipal court inadvertently failed to comply with this statute in the case before us and ordered a presentence investigation which did not include physical and mental examination, committing defendant, meanwhile, to the custody of the sheriff. That this statutory provision is mandatory is clear. Several offenses are specified, and where they are involved, the word “shall” is used. Immediately following is a provision relating to sex crimes other than those specified. As to the unspecified sex crimes, the word “may” is used and the court’s power to commit a defendant for examination is fur--ther conditioned upon the adequacy of facilities and the willingness of the department to accept him.
The statute further provides that upon completion of the examination a report of the results and the recommendation of the department shall be sent to the court. The court’s authority at that point depends upon whether the department recommends specialized treatment for the defendant’s mental and physical aberrations. If it does so recommend, the court must either place him on probation, upon condition that he receive treatment, or commit him to the department. If there is no recommendation for treatment, the court is to proceed to sentence defendant in the manner provided by law. Clearly, the legislature has authorized the department, not the court, to determine whether the defendant’s offense is to have the consequences of a crime in the traditional sense or is the manifestation of physical or mental aberration for which defendant should be treated. If the offense is, in fact, the latter, then it is in the interest both of society and the defendant that defendant receive treatment and that any restrictions imposed upon liberty should not be imposed for
*195 In the case before us, the municipal court has, in effect, exercised authority which the legislature has given to the department, namely, authority to decide whether this is a case where defendant should have specialized treatment. Therefore we conclude that the judgment must be reversed.
One further problem calls for comment. Defendant has not appealed, and he has not been represented here upon the writ of error obtained by the state. By statute the state has the right to appeal from or to obtain review by writ of error of a judgment and sentence not authorized by law. Sec. 958.12 (1) (c), Stats. This statute was held valid in a case where the state sought review of a judgment imposing a fine less than the amount prescribed by law.
State v. Stang Tank Line
(1953),
By the Court. — Judgment reversed, and cause remanded with instructions to commit defendant in error to the state department of public welfare pursuant to sec. 959.15 (1), Stats., and for further proceedings according to law. Until such commitment, defendant in error shall be held in the custody of the sheriff of Outagamie county.
