David Armstrong appeals his conviction for the sale of crack cocaine and his sentence to life imprisonment. Held:
1. Appellant contends evidence of a similar transaction was improperly admitted. He asserts the conviction as to that transaction was obtained in a trial in which he represented himself, after inadequate inquiry by that trial court as to whether appellant was indigent and whether he should have counsel appointed. The similar transaction was a sale by appellant of crack cocaine on March 31, 1989, in the same location as the offense in this case. This evidence was properly admitted. It was unnecessary to show that appellant was convicted for the offense; it was necessary only to show that appellant engaged in a transaction which was sufficiently similar to the transaction in this case to be relevant. Chastain v. State, 260 Ga. 789 (400 SE2d 329). The evidence of the transaction was not inadmissible merely because a conviction based on that transaction might be attacked.
2. Appellant was sentenced to life imprisonment for a second drug conviction under OCGA § 16-13-30 (d). He contends the sentence is unlawful because the State did not give notice pursuant to OCGA § 17-10-2 (a) that it “intended to demand recidivist punishment,” citing State v. Marshall, 195 Ga. App. 535, 536 (394 SE2d *797379). The State contends its notice of intent to use the prior conviction as evidence of a similar transaction was sufficient to permit the maximum punishment under OCGA § 16-13-30 (d).
OCGA § 17-10-2 (a) provides that in any felony case except death penalty cases, the judge in a pre-sentence hearing shall hear evidence in aggravation of punishment, “provided that only such evidence in aggravation as the state has made known to the defendant prior to [his] trial shall be admissible,” so that the court may consider evidence “in extenuation, mitigation, and aggravation of punishment, including the record of any prior criminal convictions.” This Code section applies to repeat felony offenders, as to whom the court has discretion under § 17-10-7 (a) to impose or “probate or suspend the maximum sentence prescribed for the offense.” Recidivist sentencing of felony offenders under § 17-10-2 (b) is improper when “the record does not contain any . . . affirmative notice to defendant that his prior felony offenses would be used against him for recidivist purposes during sentencing.” State v. Freeman, 198 Ga. App. 553, 556-557 (402 SE2d 529). The point of such notice in a sentencing under § 17-10-7 (a) is obvious: since the maximum sentence is discretionary, a defendant may show he is undeserving of it.
Because sentencing under § 17-10-7 (a) is a matter of discretion, § 17-10-2 (b) requires a felony defendant be given “unmistakable advance warning” that prior convictions will be’ used in aggravation of punishment. Mitchell v. State, 202 Ga. App. 100 (413 SE2d 517). This phrase originated in State v. Hendrixson, 251 Ga. 853, 854 (310 SE2d 526) which held that a prior drug conviction need not be set out in the indictment to authorize the maximum life sentence under § 16-13-30 (d). The issue was not whether § 16-13-30 (d) requires notice of intent to use a prior drug conviction in sentencing. The court used the phrase “unmistakable advance warning” in a sufficient-but-not-necessary context, citing Riggins v. Stynchcombe, 231 Ga. 589, 592-593 (203 SE2d 208). However, Riggins was a felony case not involving drugs, and Riggins was sentenced under § 17-10-2 (b) (repeat felony), not § 16-13-30 (d) (repeat drug offense). Hendrixson did not consider the fact that a life sentence for a second conviction under § 16-13-30 (d) is mandatory, and did not in fact hold that “advance warning” is necessary to authorize the mandatory sentence under § 16-13-30 (d).
In Edwards v. State, 260 Ga. 121, 122 (390 SE2d 580), the Supreme Court noted that in Hendrixson, supra, it “indicated that before the state can seek a life sentence under § 16-13-30 (d), the state must give notice before trial under § 17-10-2 (a) of the conviction the state plans to use in aggravation.” (Emphasis supplied.) This language expresses the Supreme Court’s own reluctance to hold or to say that it has held that advance notice is required when the sentence is mandatory under § 16-13-30. The statement is, moreover, dictum, *798as the point was not in issue, for the State did give notice and Edwards’ contention was merely that the mandatory provision of § 16-13-30 applies only to jury trials.
This sentence was not imposed under § 17-10-2 (b). It was mandated by Title 16, Chapter 13 (Controlled Substances). This mandate has been held constitutional. Isom v. State, 261 Ga. 596 (408 SE2d 701); Nuckles v. State, 207 Ga. App. 63, 64 (427 SE2d 54). OCGA § 16-13-30 (d) provides: “Upon conviction of a second or subsequent offense [of sale of cocaine, a person] shall be imprisoned for life” (Emphasis supplied.) The legislature thus removed the court’s sentencing discretion for second offenses under § 16-13-30 (d). A prior drug conviction is not “aggravation” of punishment to be rebutted by the defendant, argued by the parties and considered by the trial court; under § 16-13-30 (d) the court has no discretion “to probate or suspend the maximum sentence,” as it does for repeat felony offenders under § 17-10-2 (a).
The legislature enacted both §§ 16-13-30 (d) and 17-10-2 (a) at the same session in 1974. The legislature enacted the comprehensive “Controlled Substances” Act of which § 16-13-30 (d) is a part (Ga. L. 1974, p. 243); it also enacted § 17-10-2 (a) (sentencing of repeat felony offenders) (Ga. L. 1974, p. 357). In making sentencing of a repeat drug offender mandatory under § 16-13-30 (d) without requiring notice of a prior drug conviction, while providing that evidence of prior felony convictions (“evidence in aggravation”) is not admissible if they are not “made known” by the State in advance in felony sentencing under § 17-10-2 (a), the legislature made a knowing distinction: maximum sentencing under § 16-13-30 (d) is mandatory; sentencing under § 17-10-2 (a) is discretionary. Notice of prior felony convictions for discretionary sentencing under § 17-10-2 (a) is required before they can be admitted in evidence in aggravation of punishment. OCGA § 16-13-30 (d) contains no requirement of advance notice as a condition to sentencing or to receiving evidence of prior drug conviction. In a recent case, Wainwright v. State, 208 Ga. App. 777 (432 SE2d 555) (1993), we discussed what type of “notice” complies with the notice requirement of OCGA § 17-10-2 (a). Although we noted that both OCGA §§ 17-10-7 and 16-13-30 (d) “give direction as to [sentencing] under specified aggravated circumstances,” this does not imply that sentencing under § 16-13-30 (d) is discretionary. Rather, the “direction” in § 16-13-30 (d) is that the maximum sentence is mandatory upon a second drug conviction as provided in that Code section.
Because this life sentence was mandated by law under § 16-13-30 (d), notice that the State intended to use his prior conviction at sentencing would have given appellant no material benefit.
The special concurrence correctly says the defendant is presumed *799to know the law. Martin v. State, 160 Ga. App. 275, 277 (1) (287 SE2d 244). Therefore, he cannot contend he did not know his prior drug conviction made a life sentence mandatory. If he says he knew the law but did not know he had a prior drug conviction, the maximum sentence is still mandatory. Nothing in OCGA § 16-13-30 or in § 17-10-2 mitigates the mandatory sentence, for it is mandatory. Therefore, defendant’s knowledge that a prior drug conviction would be used in punishment is immaterial to the mandatory sentence imposed by the legislature in § 16-13-30. The special concurrence says advance notice is required because defendant’s foreknowledge that a judge will be forced to impose a certain sentence because of a prior drug crime may affect the plea negotiations or defense strategies. This argument suggests that a repeat drug offender has some constitutional or due process right to plea bargain or to use a certain defense, without which a sentence cannot be imposed. When it mandated a life sentence for a second drug conviction, the legislature did not concern itself with a defendant’s supposed right to plea bargain or use a certain defense, and certainly did not condition the mandatory sentence on the condition that he had fully explored his plea bargaining options and defense strategies.
It should be emphasized that § 17-10-2 does not actually require notice of anything. It merely says that at a pre-sentence hearing “only such evidence in aggravation as the state has made known to the defendant . . . shall be admissible.” This is a pre-condition to use of certain evidence in a sentencing; this pre-condition, or “requirement” for introducing evidence of prior convictions at sentencing after trial or plea, has no application to plea bargaining or defense strategy during trial. OCGA § 16-13-30, which makes a life sentence mandatory for second drug convictions, makes no pre-condition of this mandate; there is nothing to be argued, for there is no discretion in sentencing and the prior drug conviction is not “evidence in aggravation” of a discretionary sentence as in sentencing under § 17-10-2.
State v. Marshall, supra, involved four counts for sales of cocaine in one indictment; the issue was whether the State, without notice, could use a conviction of the first count to impose a life sentence for convictions of the other counts. We overrule that decision to the extent it holds that notice must be given of intent to use a defendant’s prior drug conviction to authorize sentencing under § 16-13-30 (d).
The trial court was mandated to impose the maximum sentence under § 16-13-30 (d). If for any purpose appellant was entitled to “notice,” the State’s notice of intent to use the prior conviction as a similar transaction was sufficient, as we held in Moss v. State, 206 Ga. App. 310, 312 (425 SE2d 386).
3. Armstrong contends that the prior conviction was illegal, but this sentencing proceeding is not the proper forum to determine that *800issue; if the prior conviction is held illegal in proper proceedings, this sentence may be modified as allowed by law.
Judgment affirmed.
Pope, C. J., McMurray, P. J., Cooper and Andrews, JJ., concur. Beasley, P. J., Blackburn and Smith, JJ., concur specially. Johnson, J., not participating.