
663 S.W.2d 216 (1983)
James SANDERS, Appellant,
v.
COMMONWEALTH of Kentucky, Appellee.
Ernestine SANDERS, Appellant,
v.
COMMONWEALTH of Kentucky, Appellee.
Court of Appeals of Kentucky.
September 9, 1983.
Rehearing Denied January 27, 1984.
*217 Shelby C. Kinkead, Jr., J. Randall Reinhardt, Bulleit, Kinkead, Irvin & Reinhardt, Lexington, for appellant, Ernestine Sanders.
Michael E. Cassity, Cassity, Kelly & Assoc., Mt. Orab, Ohio, for appellant, James Sanders.
Steven L. Beshear, Atty. Gen., Cicely D. Jaracz, Ethyle J. Noel, Asst. Attys. Gen., Frankfort, for appellee.
Before COOPER, HOGGE and HOWERTON, JJ.
HOWERTON, Judge.
James and Ernestine Sanders appeal from a judgment in the Mason Circuit Court with a five-year sentence for possession of a Schedule II controlled substance. They present two allegations of error. They first argue that the trial judge erred by sentencing each of them to a five-year term for possession of cocaine. The second argument is that the trial court erred by overruling their motion to suppress the evidence seized from their home on May 21, 1982.
The appellants were each indicted on four counts involving drug-related crimes in violation of KRS Chapter 218A. They were charged with trafficking in cocaine, possession of a counterfeit controlled substance, trafficking in marijuana, and possession of cocaine.
The parties moved to suppress the evidence, but the motion was denied. They then bargained with the Commonwealth and entered pleas of guilty on October 25, 1982, to the charge of possession of cocaine. On recommendation of the Commonwealth, the other charges were dismissed, and they were given five-year sentences.
The basis for the appellants' first argument is that cocaine is not a narcotic and, therefore, the five-year sentence was impermissible. Prior to July 15, 1982, KRS 218A.990(5) read:
Any person who knowingly and unlawfully possesses a controlled substance classified in Schedules I or II which is a narcotic *218 drug shall, for the first offense, be confined in the penitentiary for not less than one (1) year nor more than five (5) years . . . .
At that time, the penalty for possessing a nonnarcotic Schedule II drug carried a maximum sentence of a $500.00 fine and one year in the county jail. KRS 218A.990(3).
Some confusion may have been created by the amendment to KRS 218A.990, which became effective July 15, 1982. Subsection (7) now reads:
Any person who knowingly and unlawfully possesses a controlled substance classified in Schedules I or II which is a narcotic drug or which is included in KRS 218A.070(1)(d) shall, for the first offense be confined in the penitentiary for not less than one (1) year nor more than five (5) years . . . .
KRS 218A.070 relates to "Schedule II Controlled Substances." It has not been amended, and Subsection (1)(d) reads, "coca leaves and any salt, compound, derivative, or preparation of coca leaves . . . ." Cocaine was, thus, specifically covered in the one to five-year penalty by the new language in KRS 218A.990(7).
The appellants and the Commonwealth attempt to argue what the legislature did or did not intend by the original statutes and by the amendment. We find none of the arguments to be dispositive. KRS 218A.010(10), both before and after July 15, 1982, defined "narcotic drug" to mean, among other things, "coca leaves and any salt, derivative, or preparation of coca leaves . . . ." KRS 218A.010(10)(d). The definition is identical to the language in KRS 218A.070.
The appellants present a lengthy brief attempting to explain that cocaine is a nonnarcotic. This may or may not be technically correct. It is quite apparent, however, that the legislature chose to include cocaine in its definition of narcotics and to treat it the same as a narcotic prior to July 15, 1982. This they had a right to do, and the penalty for possession of this drug was clearly to be one to five years.
When James and Ernestine Sanders entered their guilty pleas, they signed documents indicating that they understood their rights and that the only promises made to them were that the Commonwealth would recommend a five-year sentence for possession of cocaine and a dismissal of the remaining three counts. They also indicated in their signed statement that they understood that under the original charges each could be sentenced for as long as 18 years and fined as much as $19,000.00. We find no error in the sentencing procedure and no basis for reversal on that allegation.
The Commonwealth has argued that the appeal should be dismissed because there is no direct appeal from a plea of guilty. Generally, a plea of guilty constitutes a waiver of all defenses other than that the indictment charged no offense. White v. Sowders, 644 F.2d 1177 (6th Cir. 1980), and Quarles v. Commonwealth, Ky., 456 S.W.2d 693 (1970). The situation and question in this appeal are very unique, and they create an exception to the general rule. The parties pled guilty but then argued that they received an impermissible punishment. No one questions the validity of the pleas, and the record indicates that the pleas were entered voluntarily, knowingly, and intelligently, satisfying the standards set out in Boykin v. Alabama, 395 U.S. 238, 89 S.Ct. 1709, 23 L.Ed.2d 274 (1969). We have heretofore decided that the punishment was appropriate.
As to the second issue, the Commonwealth argues that the appellants waived their right to challenge the search warrant and the seizure of the evidence when they pled guilty. We agree that the issue of the evidence has been waived, but having reviewed the entire record, we can conclude that the search was lawful and that the trial court properly denied the motion to suppress the evidence. The search resulted in the discovery of the cocaine, and the search warrant was based on a number of facts and events involving information from a reliable confidential informant and *219 the observations of several peace officers in Mason County.
The judgment and sentences of the Mason Circuit Court are affirmed.
All concur.
