
431 N.W.2d 193 (1988)
STATE of Iowa, Plaintiff-Appellee,
v.
Craig Brian GLENN, Defendant-Appellant.
No. 87-1803.
Court of Appeals of Iowa.
August 24, 1988.
As Corrected November 10, 1988.
Keith D. Collins of Norgaard & Collins, Belle Plaine, for defendant-appellant.
Thomas J. Miller, Atty. Gen., Mark Hunacek, Asst. Atty. Gen., and Brent Heeren, Tama Co. Atty., for plaintiff-appellee.
*194 Considered by DONIELSON, P.J., and SCHLEGEL and HAYDEN, JJ.
DONIELSON, Presiding Judge.
Defendant entered a guilty plea to a charge of operating a motor vehicle while intoxicated, first offense. He was sentenced to 180 days in jail, with all but 30 days suspended. He was also placed on probation for two years. He was directed to undergo inpatient substance abuse treatment, with the time spent in such treatment to be credited against the 30-day jail term.
On this appeal, defendant contends he is entitled to a remand for resentencing because he was denied his right to address the court personally in mitigation of his sentence. He also contends the sentence imposed was outside the court's authority in that inpatient treatment is not authorized by statute for first offenses.
At the sentencing hearing, defendant appeared without counsel. When asked if there was any reason why the judge should not go ahead and sentence him, defendant replied, "No." The court also elicited from the defendant a statement that he understood the presentence recommendation.
After discussing defendant's employment situation, the sentence previously described was announced. This sentence matched the recommendation made in the presentence report. Defendant appeals this sentence claiming he was denied his right to address the court personally in mitigation of his sentence and that substituting court-ordered inpatient treatment for jail is not authorized by statute.
Our review of this case is for correction of errors at law. Iowa R.App.P. 4.
Defendant asserts that the trial court failed to provide him an opportunity to personally address the court in mitigation of punishment prior to imposing sentence as provided by Iowa Rule of Criminal Procedure 22(3)(d). The rule provides in pertinent part: "Prior to such rendition [of judgment] ... the defendant personally shall be allowed to address the court where [he] wishes to make a statement in mitigation of punishment." Iowa R.Crim.P. 22(3).
At the sentencing hearing, the judge and defendant received a copy of the presentence report. The judge then asked the State if there was any reason why he should not sentence defendant at this time. The State answered in the negative. Then the court asked defendant, "Any reason I should not go ahead right now and sentence you?"
Mr. Glenn replied, "No."
The court then asked for and received the State's recommendation. Glenn was asked if he understood what was said and he said, "Yes."
The court then asked Glenn what he understood the recommendation to be. Glenn replied, "Going through an inpatient substance abuse or the jail time, and then a period of probation afterward."
The court then said, "Okay. What do you say about that? Are you working right now?"
To which Glenn replied just, "Yeah."
After discussing with Glenn where he worked, the court then addressed questions about the inpatient treatment to the person who offered the recommendation. The judge then pronounced Glenn's sentence. This exchange between the court and defendant provided defendant adequate opportunity to address the court. The court is not required to use any particular language to satisfy rule 22(3)(d). Substantial compliance is sufficient. Furthermore, defendant was allowed to comment in writing about the proposed treatment. His only comment expressed concern that he be able to work.
Prior to January 1, 1978, the right to allocution was described in Iowa Code section 789.6. It required that defendant be asked "whether he has any legal cause to show why judgment should not be pronounced against him." Iowa Code § 789.6 (1977). Under this statute, it was held that the right of allocution had been provided even though the explicit language was not used. State v. Christensen, 201 N.W.2d 457, 460 (Iowa 1972). Being asked, "Is there anything you would like to say to the *195 court before I pronounce sentence?" was held sufficient. Id.
In reaching this result, the court discussed previous cases wherein the purpose of this statute was discussed. An extended question and answer colloquy between the court and the defendant was deemed sufficient where defendant had ample opportunity to volunteer any information helpful to his cause. State v. Patterson, 161 N.W.2d 736, 736 (Iowa 1968). "The important thing is whether defendant had his chance to point out any reason for withholding judgment." Id.
Defendant Glenn was given such an opportunity. To require more under the current rule would violate rules of statutory construction. The court is to construe the meaning of a statute by what the legislature said instead of what it should or might have said. The rule says only that defendant shall be allowed to address the court.
Our position is further strengthened when we compare section 789.6 with rule 22(3)(d). The explicit question that was to be asked in section 789.6 has been removed. From this, it can be inferred that the legislature intended to codify what the courts had accepted under section 789.6. That is, as long as the court provides defendant with an opportunity to speak regarding his punishment, the court is in compliance with the law. Rule 22(3)(d) is a mandatory requirement for allocation. This was provided to Glenn; therefore, there is no need to remand this case.
Defendant also asserts that ordering an OWI, first offender to undergo inpatient substance abuse treatment in lieu of a thirty-day jail sentence is not authorized by statute and thus void. The State maintains the court had authority to order substance abuse treatment as a condition of defendant's probation. We agree with the State's position.
As long as the sentence imposed is within the statutory maximum, this court will interfere only when the trial court has abused its discretion. State v. Avritt, 376 N.W.2d 634, 634 (Iowa App.1985). A person who violates Iowa Code section 321J.2 commits a serious misdemeanor for the first offense. Iowa Code § 321J.2(2)(a) (1987). The maximum sentence a court may determine for a serious misdemeanor is "imprisonment not to exceed one year, or a fine not to exceed one thousand dollars or both." Id. § 903.1(1)(b). However, application of section 903.1(1)(b) is conditioned upon not having a specific penalty provided for the offense. Id. § 903.1.
Iowa Code section 321J.2(2)(a) provides that a person who commits a first offense "shall be imprisoned in the county jail for not less than forty-eight hours, to be served as ordered by the court, less credit for any time the person was confined in a jail or detention facility following arrest...." (emphasis added). This statute provides a minimum sentence to be imposed for first offenders. Therefore, as long as the court ordered a sentence within the range provided by the statutes, there is no abuse of discretion.
The lower court ordered the defendant to serve 180 days in the county jail. However, all but thirty days of this sentence were suspended. The 180 days falls within the statutory range. The suspension of the sentence is authorized by Iowa Code section 356.47. A judge who sentences a person to the county jail may suspend any part of such sentence and place such person on probation. The sentencing judge may direct the terms and conditions of the probation. Iowa Code § 356.47.
The lower court placed defendant on probation for two years. The defendant was also ordered to undergo inpatient substance abuse treatment, with the time counting toward the jail sentence.
Iowa Code section 907.3(2) also provides that a court may suspend the sentence and put the defendant on probation upon such terms and conditions as it determines necessary including, but not limited to, commitment to an alternate jail facility or a community correctional residential treatment facility. Conditions established by the judicial district department of correctional services will be followed with court approval. Iowa Code § 907.6. And the court may impose "any additional reasonable *196 conditions" in order to "promote rehabilitation of the defendant or protection of the community." Id.
The lower court adopted the presentence recommendation of the Sixth Judicial District Department of Correctional Services in the sentence announced. The reasons given by the court for this judgment and sentence were: defendant's record of convictions; the recommendation of the probation officer and the State; and because of the nature of the offense and defendant's past history of substance abuse.
The court did not abuse its discretion rendering this sentence upon Glenn. The reasons given and the sentence imposed are consistent with our policy objectives. The Iowa legislature has given increased emphasis to evaluation and treatment of persons with substance abuse problems. This objective was found to be furthered by the presentence substance abuse evaluation. State v. Moyer, 382 N.W.2d 133, 135 (Iowa 1986). The evaluation is mandatory for second offenders or those with an alcohol concentration of .20 or higher. Iowa Code § 321J.3(1). But the purpose of the evaluation is equally important to defendants like Glenn with a record of offenses involving alcohol. Likewise, the treatment of Glenn is consistent with this policy. Ordering inpatient substance abuse treatment is a reasonable condition which promotes rehabilitation of the defendant and helps protect the community from future violations. Therefore, we affirm the lower court.
AFFIRMED.
