
105 Wn.2d 511 (1986)
716 P.2d 875
THE STATE OF WASHINGTON, Respondent,
v.
COLLEEN MARIE AUSTIN, Petitioner.
No. 51354-6.
The Supreme Court of Washington, En Banc.
March 27, 1986.
Raymond H. Thoenig of Washington Appellate Defender Association, for petitioner.
Norm Maleng, Prosecuting Attorney, and Edwin K. Inkley, Deputy, for respondent.
DOLLIVER, C.J.
Defendant challenges imposition of a 2-year sentence for a violation of the Uniform Controlled Substances Act (UCSA) (RCW 69.50) claiming her crime was an anticipatory offense punishable by a maximum of 1 year. We affirm the trial court and uphold the imposition of a 2-year sentence.
By amended information filed September 18, 1981, the King County Prosecutor charged Austin with obtaining "a controlled substance ... by means of a false and forged prescription ... [c]ontrary to RCW 69.50.403(a)(3) ..." The prosecutor also accused Austin, in count 2, of "the crime of attempted violation of the [UCSA], a crime of the same or similar character as Count I ..." With respect to this latter charge, the information stated Austin "did willfully, *513 unlawfully and feloniously attempt to obtain a controlled substance ... by means of a false and forged prescription ... [c]ontrary to RCW 69.50.403(a)(3) ..."
Austin agreed to plead guilty to count 2. In return, the State agreed to dismiss count 1. Austin executed a "Statement of Defendant on Plea of Guilty (Felony)", in which she admitted the following:
I gave an undercover police officer a prescription that was forged, for Percodan. I did not fill out the prescription, but I did fill out the name on the prescription. I went with him when he went to pass the prescription for the tablets.
She also indicated she understood she could be sentenced to prison for a maximum term of 2 years for "[a]ttempted [violation of the UCSA]".
At the hearing on Austin's plea of guilty, the following colloquy occurred:
THE DEFENDANT: Is it true that an attempted [violation of the UCSA] carries the same fine and jail sentence as a regular violation of the Uniform Controlled Substances Act?
THE COURT: State prepared to respond to that?
[State]: Your Honor, the only thing I can say at this point is that the maximum penalty for this particular offense is 2 years and and/or a $2000 fine.
[Defense Counsel]: ...
RCW 69.50.403 talks about attempted [violation of the UCSA and a violation of the UCSA] in the same light and the same penalty. It's a separate penalty scheme.
THE COURT: Miss Austin, do you want to proceed or do you want to confer with your attorney some more?
THE DEFENDANT: I'll plead guilty to the charge.
...
THE COURT: You feel you fully understand everything?
THE DEFENDANT: Um-hum.
The trial court deferred imposition of sentence for 2 years and placed Austin on probation, subject to certain specified conditions. Subsequently, on May 26, 1983, the court found Austin had violated the terms of her probation. The court revoked her probation and imposed sentence of *514 imprisonment for 2 years.
Austin appealed. The Court of Appeals affirmed the trial court. State v. Austin, 39 Wn. App. 109, 692 P.2d 206 (1984). We accepted her petition for review pursuant to RAP 13.4(b)(2).
Defendant was charged with a violation of RCW 69.50.403 (a)(3)(ii), which states:
It is unlawful for any person knowingly or intentionally:
...
(3) To obtain or attempt to obtain a controlled substance, or procure or attempt to procure the administration of a controlled substance, ... (ii) by forgery or alteration of a prescription or any written order ...
(Italics ours.) A violation of this section carries a maximum penalty of 2 years and is a class C felony. RCW 9A.28.010(3).
The defendant claims that because she was charged with an attempted violation of the UCSA (RCW 69.50.403(a)(3)(ii)), she should have been sentenced for an anticipatory offense under the general attempt statute (RCW 9A.28.020) and therefore could only be sentenced to a maximum of 1 year's imprisonment as a gross misdemeanor. RCW 9A.28.020(1) reads:
A person is guilty of an attempt to commit crime if, with intent to commit a specific crime, he does any act which is a substantial step toward the commission of that crime.
[1] In construing the former criminal code, this court has held the general attempt statute applicable only when there is no specific statutory provision making an "attempt" an included crime. State v. Gjertson, 71 Wn.2d 757, 430 P.2d 972 (1967). In Gjertson, the defendants were convicted of attempted escape. The defendants argued their sentences exceeded the maximum sentence allowable under the general attempt statute. We rejected this argument reasoning that the defendants "were not convicted of an attempt to commit a felony; they were convicted of a *515 felony, i.e., a violation of [former] RCW 9.31.010 ..., which makes either an escape or an attempt to escape a felony in itself." Gjertson, at 759. The court noted that, by its terms, former RCW 9.01.070 applied to "every person who attempts to commit a crime, unless otherwise prescribed by statute ..." Gjertson, at 758 n. 2. We further added that it was the intent of the Legislature to make the punishment of an attempt to commit a serious crime as serious an offense as commission of the crime itself. Gjertson, at 759.
The Court of Appeals applied similar reasoning to the newly enacted criminal code. State v. Langworthy, 20 Wn. App. 822, 826, 583 P.2d 1231 (1978), rev'd on other grounds, 92 Wn.2d 148, 594 P.2d 908 (1979). Langworthy held the specific conspiracy provision of the UCSA controls, to the exclusion of the general conspiracy statute in sentencing. State v. Langworthy, supra. In dismissing the defendant's equal protection claim, the court held the prosecutor was mandated to proceed under the special UCSA statute, RCW 69.50.407. Langworthy, at 828 (applying the rule that a special statute supersedes a general statute, State v. Carroll, 81 Wn.2d 95, 500 P.2d 115 (1972)).
The Court of Appeals in this case adhered to the holdings in Gjertson and Langworthy. Even though the general attempt statute, RCW 9A.28.020, no longer states that it applies only to crimes not otherwise prescribed by statute, the lower court reasoned that the concept still is valid. State v. Austin, supra at 112. The court noted that the current Washington Criminal Code provides a similar distinction in RCW 9A.04.010(2):
The provisions of this title shall apply to any offense ... which is defined in this title or in the general statutes, unless otherwise expressly provided or unless the context otherwise requires .. .
(Italics ours.)
In 1979 the Court of Appeals decided the case allegedly in conflict with the present case. State v. Hansford, 22 Wn. App. 725, 591 P.2d 482 (1979). In Hansford, the court held *516 the State could charge the defendant with attempted extortion under the general attempt statute (RCW 9A.28.020) even though there was a specific statute defining extortion as knowingly obtaining or attempting to obtain the property or services of the owner by a threat (RCW 9A.56.110). The court distinguished Gjertson on the grounds that it had applied a markedly different attempt statute and was, therefore, no longer valid today. Hansford, at 728.
The Hansford case is not in conflict with the present case nor did Hansford need to validate its holding by distinguishing the Gjertson case. RCW 9A.56.110 defines extortion as "knowingly to obtain or attempt to obtain by threat property or services of the owner ..." Defendant Hansford was charged with taking a "substantial step toward [RCW 9A.28.020] knowingly attempting to obtain property from the owner thereof ..." Hansford, at 727. Pursuant to RCW 9A.56.120(1), extortion in the first degree is committed "by means of a threat as defined in RCW 9A.04.110(25)(a), (b), or (c)." The Court of Appeals analysis is somewhat murky, but it seems simply to sidestep the question of whether there was a sufficient threat as defined by RCW 9A.04.110(25)(a), (b), or (c) to constitute extortion. Rather it held that the actions of defendant Hansford  his "early morning unlawful entry of the premises, his attire and armament, the threatening note and the Model Penal Code [Proposed Official Draft 1962] definition of `substantial step,'" (Hansford, at 729)  were sufficient to uphold his conviction of the attempt under RCW 9A.28.020 to commit the crime of attempted first degree extortion.
In both the present case and the Gjertson case, however, the attempt was the actual completed crime. In Hansford, the completed crime of extortion required an actual threat, not an attempted threat; the defendant's note in Hansford constituted an attempted threat and, thus, was a crime only pursuant to the general attempt statute, RCW 9A.28.020. Attempting to obtain a controlled substance under RCW 69.50.403(a)(3), however, is not simply a "substantial step"; *517 it is the crime itself.
Although the Court of Appeals in the present case does determine correctly that the general attempt statute does not apply to RCW 69.50.403(a)(3), its analysis of the case stops short. The question remains as to whether a defendant may plead guilty to a greater offense than the one improperly charged.
While a defendant may plead guilty to a lesser included offense or to a crime of an inferior degree, State v. Wilmot, 95 Wash. 326, 163 P. 742 (1917), the crimes for which a person may be convicted are limited to those charged in the information. State v. Foster, 91 Wn.2d 466, 589 P.2d 789 (1979). Accord, State v. Martin, 94 Wn.2d 1, 614 P.2d 164 (1980). There are two recognized exceptions to this latter rule: (1) where a defendant is convicted of a lesser included offense, RCW 10.61.006; and (2) where a defendant is convicted of a crime of an inferior degree to the one charged, RCW 10.61.003. State v. Foster, at 471.
[2] Defendant was charged with attempted violation of RCW 69.50.403(a)(3), a gross misdemeanor (RCW 9A.28.020(3)(d)); she pleaded guilty to a violation of RCW 69.50.403(a)(3), a class C felony. The question is whether she may plead guilty to the greater offense. This court has held that when a technical defect is not jurisdictional, plea agreements have been upheld where the plea was entered into voluntarily and knowingly, and the defendant was fully aware of the consequences. State v. Majors, 94 Wn.2d 354, 616 P.2d 1237 (1980). See also State v. Osborne, 102 Wn.2d 87, 684 P.2d 683 (1984).
The record before us reveals the defendant was represented at all stages of the proceedings and understood that either count of her violation carried the same punishment. Even though the original charge stated, incorrectly, "attempted violation of the Uniform Controlled Substances Act", it also stated this was a crime of the same or similar character as a violation of the UCSA. At the time of defendant's plea, she testified she understood she could be sentenced to 2 years in prison and that she knew *518 "attempted [violation of the] UCSA and [violation of the] UCSA carrie[d] the same fine and jail sentence ..." Defendant also signed a plea form which clearly indicated she was pleading guilty to a felony and not to a gross misdemeanor. Even though the original charge was incorrectly stated, defendant should be held to her subsequent understanding.
We affirm the trial court and uphold defendant's conviction of violating the Uniform Controlled Substances Act when she attempted to obtain a controlled substance.
UTTER, BRACHTENBACH, DORE, PEARSON, ANDERSEN, CALLOW, and GOODLOE, JJ., and WILLIAMS, J. Pro Tem., concur.
