The opinion of the court was delivered by
Davis, J.:This is an attempted appeal by the State from a trial court ruling vacating the defendant’s plea of guilty. Because the State does not satisfy any of the statutory grounds authorizing an appeal to this court, we dismiss for lack of jurisdiction.
The facts of this case are unique and somewhat complicated. The defendant was originally charged with one .count of possession of methamphetamine under K.S.A. 1993 Supp. 65-4127a. Normally, possession would be a severity level 4 felony, but the defendant was charged with a severity level 1 felony offense based upon his two prior convictions in 1988 under the provisions of K.S.A. 1988 Supp. 65-4.127b for. sale of methamphetamine. See K.S.A. *8231993 Supp. 65-4127a(c). The defendant was also charged with one count of unlawful possession of drug paraphernalia.
The defendant entered into a plea agreement with the State whereby he agreed to enter a plea of nolo contendere to the felony charge of possession in exchange for the State’s agreeing to (1) dismiss the drug paraphernalia charge and (2) amend the possession of methamphetamine charge to possession of methamphetamine, having once been convicted under the Uniform Controlled Substances Act for sale of methamphetamine. The second provision of the plea agreement had the effect of reducing his crime of possession of methamphetamine from a severity level 1 felony to a severity level 2 felony. See K.S.A. 1993 Supp. 65-4127a(c). Pursuant to the agreement, the defendant pled no contest to the amended charge, and the court, satisfied that a factual basis existed, accepted his plea and found him guilty.
Prior to sentencing, the defendant filed a motion captioned “Objections to Criminal History Classification and Severity Level.” He argued that his prior 1988 convictions for sale of methamphetamine could not be used to enhance his current offense. The defendant’s argument is based upon K.S.A. 1993 Supp. 65-4127a:
“(c) If any person has a prior conviction under this section or a conviction for a substantially similar offense from another jurisdiction, then that person shall be guilty of a drug severity level 2 felony and if the person who violates this section has two or more prior convictions under this section or substantially similar offenses under the laws of another jurisdiction, then such person shall be guilty of a drug severity level 1 felony.” (Emphasis added.)
The defendant argued that his two prior convictions for possession of methamphetamine occurred in 1988 under the provisions of K.S.A. 1988 Supp. 65-4127b rather than under K.S.A. 1988 Supp. 65-4127a; therefore, they were not under this section as provided for under K.S.A. 1993 Supp. 65-4127a(c) and could not be used to make his most recent conviction a severity level 2 felony.
At the hearing on his motion, the defendant did not ask the court to vacate the plea agreement but instead asked that his current conviction be properly counted as a drug severity level 4 offense and that his prior convictions be used to determine the appropriate criminal, history category of F. In the alternative, the defendant *824asked that if the court held the current conviction to be a drug severity level 2 offense, that his prior criminal history should not include either prior conviction because under K.S.A. 1993 Supp. 21-4712 they would be elements of or used to enhance the severity level of the current criminal conviction. The State argued that the defendant had already pled no contest and should not now be allowed to unilaterally rewrite the plea bargain.
After taking the issue under advisement, the court held that the defendant’s conviction for sale of methamphetamine under a previous statute did not constitute a prior conviction under K.S.A. 1993 Supp. 65-4127a(c) because the conviction was not under this section as set forth in K.S.A. 1993 Supp. 65-4127a(c). The court vacated the defendant’s plea, finding that the factual statement supporting the plea was incorrect and that his plea of nolo conten-dere should not have been accepted. The court found that neither party was bound by the plea agreement.
Turisdiction
The State attempts to perfect its appeal under K.S.A. 22-3602(b), which provides that appeals may be taken from cases before a district court judge as a matter of right from an order arresting judgment. The State argues that the effect of the district court’s decision was that of an order arresting judgment. The right to appeal is statutory, and in the absence of a statute authorizing an appeal, an appeal is not available to the losing party in the district court. State v. Bickford, 234 Kan. 507, 509, 672 P.2d 607 (1983).
K.S.A. 22-3502 provides that the court shall arrest judgment on motion of the defendant if the complaint, information, or indictment does not charge a crime or if the court was without jurisdiction of the crime charged. See State v. Crozier, 255 Kan. 120, 123, 587 P.2d 331 (1978). K.S.A. 22-3503 states that the court may arrest judgment on its own motion if it becomes aware of the existence of grounds to do so.
The information or indictment in this case did charge a crime, and the court had jurisdiction over the crime charged. However, based upon the trial court’s interpretation of K.S.A. 1993 Supp. *82565-4127a(c), the court concluded that the evidence was not sufficient to convict the defendant of the crime charged. We have held that a motion for arrest of judgment does not test the sufficiency of the evidence to convict the defendant of the crime. State v. Sims, 254 Kan. 1, 9, 862 P.d 359 (1993).
In its journal entry, the trial court stated that “the factual statement of the State of Kansas at the Change of Plea on December 14, 1994, was incorrect and should not have been accepted by the Court and that this matter is jurisdictional.” The State would have us rule that the complaint in this case did not charge a crime and that vacating the plea was therefore an arrest of judgment. Notwithstanding the comment by the trial court that the matter was jurisdictional, the basis for the trial court’s action in this case was its conclusion that there was an insufficient factual basis for acceptance of the defendant’s plea. K.S.A. 1993 Supp. 65-4127a, under which the defendant was convicted, outlines the basic offense and provides that it is a severity level 4 crime. K.S.A. 1993 Supp. 65-4127a(a).
K.S.A. 1993 Supp. 65-4127a(c), when applicable, relates to punishment for the crime charged and does not make the defendant’s two prior convictions elements of the crime charged. The question of whether the evidence presented by the State in its factual basis was sufficient to support a plea does not affect the jurisdiction of the court. The vacation of the defendant’s plea of nolo contendere was not an arrest of judgment under the provisions of K.S.A. 22-3602(b), and we have no jurisdiction to consider this appeal.
Appeal dismissed.