
603 So.2d 916 (1992)
James B. ZICKLER
v.
Thomas F. SHULTZ, et al.
1901802.
Supreme Court of Alabama.
July 10, 1992.
Rehearing Denied August 7, 1992.
*917 J. Michael Tanner of Almon, McAlister, Ashe, Baccus & Tanner, Tuscumbia, for appellant James B. Zickler.
Michael F. Ford of Munsey, Ford & Heflin, Tuscumbia, for appellees James N. Jeter, Jr. and Thomas F. Shultz.
Robert H. McKenzie of Holt, McKenzie, Holt & Mussleman, Florence, for appellee Manuel Eugene Turner.

ON APPLICATION FOR REHEARING
SHORES, Justice.
On January 24, 1992, this Court issued its original opinion in this case, affirming the judgment. An application for rehearing was filed on February 7; the application for rehearing is granted and the original opinion in this case is withdrawn and the following is substituted therefor.
The plaintiff, Dr. James B. Zickler, appeals from a summary judgment in favor of the defendants, Dr. James N. Jeter, Jr., Dr. Thomas F. Shultz, and Dr. Manuel Eugene Turner, in this action to recover damages for breach of contract and on a guaranty agreement. We reverse and remand.
Dr. Zickler, an anesthesiologist, decided to retire from his practice in North Alabama in 1987. He agreed to sell his practice to North Alabama Anesthesiology Group, P.C. ("NAAG"), a professional corporation owned by Drs. Jeter, Shultz and Turner. The terms of the sale were initially set forth in a "Memorandum of Understanding" that provided that NAAG would immediately pay Dr. Zickler $10,000 for his contract rights to practice at Humana Hospital in Florence and would also pay him $215,000 in 60 equal monthly installments of $3,583.33 (to be personally guaranteed by the three doctors) for his agreement to give up his practice and not to compete in the practice of medicine for five years. The total contract package was $225,000.
NAAG's business manager, Steve MacMullin, then requested that the purchase agreement be drawn so as to treat the purchase price as payment for consulting services because of the tax advantage it would afford the purchasing doctors. Expenses paid under a consultation agreement could be claimed as business expenses and deducted by NAAG and the guarantors.[1]
The "Purchase Agreement" was then drawn by Dr. Zickler's attorney, at MacMullin's behest; it incorporated by reference a "Consultation Agreement" whereby Dr. Zickler agreed to consult with NAAG, and a "Guaranty Agreement" whereby the purchasing doctors personally guaranteed payment of NAAG's $215,000 obligation under the Consultation Agreement.
This scheme was set up to give the purchasing doctors the maximum tax advantage. *918 It would allow them to deduct their payments to Dr. Zickler. Dr. Zickler agreed to this arrangement. The new contract would give him monthly income that would be sufficient until he was able to draw out of his retirement fund, which was the result he was seeking.
NAAG paid the initial $10,000 to Dr. Zickler, but later defaulted on its monthly payments. Dr. Zickler sued NAAG, alleging breach of contract, and he sued the purchasing doctors individually, under the Guaranty Agreement. Thereafter, NAAG filed a bankruptcy petition, seeking to reorganize under Chapter 11 of the Bankruptcy Code, 11 U.S.C. § 1101 et seq. The bankruptcy court confirmed a plan of reorganization of NAAG that specifically discharged NAAG as well as Drs. Jeter and Shultz, individually, from any liability to Dr. Zickler in connection with the sale of his practice.[2] Dr. Zickler contends that he did not have notice of the bankruptcy proceeding. He did not appeal the bankruptcy court's judgment.
Dr. Zickler sued on March 3, 1989. The purchasing doctors answered; Drs. Shultz and Jeter also asserted a counterclaim. After discovery was completed, the plaintiff moved for a summary judgment on his claim and on the counterclaim. The purchasing doctors responded by moving for a summary judgment. On March 18, 1991, the trial court entered a summary judgment for Drs. Jeter, Shultz, and Turner, without stating its reasons for doing so. Dr. Zickler appealed. We reverse and remand.
The summary judgment was proper in this case if there was no genuine issue of material fact and the defendants were entitled to a judgment as a matter of law. Rule 56, A.R.Civ.P. The purchasing doctors argue that they were entitled to a judgment as a matter of law. They argue that the $215,000, payable in 60 equal monthly installments, provided for in the purchase agreement, was based upon an agreement not to compete that is void under § 8-1-1, Code of Alabama 1975, and which is, therefore, unenforceable. In addition, they contend that the bankruptcy court's plan of reorganization, which discharges the doctors of personal liability to Dr. Zickler, was res judicata with respect to Dr. Zickler's claims against them based on the Guaranty Agreement. We disagree.
The agreement that is the basis for this suit is a "Purchase Agreement" for the purchase of an ongoing medical practice. The agreement not to compete was only a part of the package, as was the Consultation Agreement. The Purchase Agreement was drawn to the specifications of the purchasing doctors and for their benefit. They personally guaranteed payment for this practice, which they now seek to avoid.
The obligation of a guarantor under a contract is settled law in Alabama. A guarantor's ignorance of the contents of a guaranty agreement will not excuse his obligation under the contract, unless fraud is shown. Medley v. SouthTrust Bank of the Quad Cities, 500 So.2d 1075, 1079 (Ala.1986); First National Bank of Mobile v. Horner, 494 So.2d 419, 420 (Ala.1986); Real Coal, Inc. v. Thompson Tractor Co., 379 So.2d 1249, 1251 (Ala.1980).
The evidence reflects that the purchasing doctors signed the Guaranty Agreement. The five-page purchase agreement was signed on June 30, 1987, by Steve MacMullin for NAAG, and his signature was attested by Dr. Turner as president of NAAG. Drs. Turner, Shultz, and Jeter all signed the Purchase Agreement and the Guaranty Agreement individually. All of the signatures were acknowledged before a notary public, and the acknowledgment clause stated that the signers "acknowledged before me on this day that, being informed of the contents of said instrument, they executed the same voluntarily on the day that same bears date." Each page of the Purchase Agreement and Guaranty Agreement was also initialed by the parties.
Despite this, the purchasing doctors argue that there was no meeting of the *919 minds. The purchasing doctors are educated men; they signed these agreements before a notary, after consultation with their business manager, their counsel, and their accountant. They now seek to avoid their obligation by claiming that they failed to read the documents. If they failed to read the documents, that is not Dr. Zickler's fault. We have said that, as a matter of law, "a person with the ability to read and understand the nature of the transaction, cannot rely on an oral representation when that representation is followed by an executed document that contradicts it." Alfa Mutual Insurance Co. v. Northington, 561 So.2d 1041, 1046 (Ala.1990).
The summary judgment in this case was improper, because there is substantial evidence that the Purchase Agreement reflected a meeting of the minds of the parties. The documents themselves are executed and acknowledged and are evidence that the parties intended them to be the final agreement. The Purchase Agreement states: "This agreement specifically supersedes all understandings of the parties contained in the Memorandum of Understanding dated the 24th of June, 1987."
Dr. Shultz testified in his deposition that he knew that the Consultation Agreement was part of the agreements when he signed them and that he further knew that the agreements were "substantially different" from the original Memorandum of Understanding; yet he signed them. This is certainly substantial evidence of his assent to the Consultation Agreement. Dr. Turner signed the Consultation Agreement, attesting NAAG's agreement to it; that fact is evidence that he intended to be bound by its terms (which were different from the terms of the Memorandum of Understanding).
The Memorandum of Understanding that was first signed by the parties states that "the parties have agreed to a sale and wish to confirm their understanding in writing for said purchase and sale prior to a final closing." It also states that it is a "guide a for the activities of the parties prior to the consummation of the transaction" and that it contemplates the execution of final documentation.
Furthermore, there is substantial evidence that the purchasing doctors, as principals, had constructive knowledge of all material facts that their agent, Steve MacMullin, acquired while acting within the scope of his authority. There is a presumption in Alabama that an agent told his principal all facts within his knowledge necessary for the principal's protection or guidance. Sullivan v. Alabama Power Co., 246 Ala. 262, 20 So.2d 224 (1944). Steve MacMullin was the agent and business manager for NAAG and the guarantors in negotiating the agreements. The terms were drawn to his specifications by Dr. Zickler's counsel. A meeting of the minds as to the terms of these signed and executed agreements occurred through the principals' constructive knowledge acquired through their agent. Board of Commissioners of Alabama State Bar v. Jones, 291 Ala. 371, 281 So.2d 267 (1973).
We also must consider whether the trial court erred in holding that the bankruptcy court's plan of reorganization, which discharges the doctors of personal liability to Dr. Zickler, was res judicata with respect to Dr. Zickler's claims against the purchasing doctors.
This Court has said:
"Alabama law requires four elements for the application of res judicata. First, there must be a substantial identity between the parties in the prior and subsequent suits. Second, there must be the same cause of action in both suits. Third, the previous case must have been decided by a court of competent jurisdiction. Fourth, the previous adjudication must have reached the merits of the case. Missildine v. Avondale Mills, Inc., 415 So.2d 1040, 1041 (Ala.1981)."
Higgins v. Henderson, 551 So.2d 1050, 1052 (Ala.1989).
"If these essential elements are met, any issue that was, or could have been, adjudicated in the prior action is barred from further litigation. Trimble v. Bramco Products, Inc., 351 So.2d 1357 (Ala. 1977)." *920 Wood v. Tricon Metals & Services, Inc., 548 So.2d 138, 140 (Ala.1989).
Based on long-established Alabama law, we conclude that the doctrine of res judicata does not bar Dr. Zickler's claim. First, the bankruptcy proceeding is not based on the same cause of action as that involved in the present case. Furthermore, Dr. Zickler could not have sued Drs. Jeter and Shultz in the bankruptcy proceeding. They were not parties; only NAAG was a party.
Under Alabama law, to be res judicata, a judgment must be rendered by a court with subject matter jurisdiction. Id. The bankruptcy court went beyond its jurisdiction when it purported to release and discharge Drs. Shultz and Jeter from liability in a bankruptcy case in which neither was a debtor. Bankruptcy courts are without authority to discharge the liability of non-debtor guarantors in a bankruptcy proceeding. Union Carbide Corp. v. Newboles, 686 F.2d 593, 595 (7th Cir.1982). "The bankruptcy court can affect only the relationships of debtors and creditor. It has no power to affect the obligations of guarantors." R.I.D.C. Industrial Development Fund v. Snyder, 539 F.2d 487, 490 n. 3 (5th Cir.1976), cert. denied, 429 U.S. 1095, 97 S.Ct. 1112, 51 L.Ed.2d 542 (1977). The bankruptcy statute provides that the confirmation of the plan discharges "the debtor." Neither doctor was a debtor; only NAAG was in court. Therefore, the bankruptcy judgment was not res judicata to Dr. Zickler's claims against the guarantors.
The summary judgment is due to be reversed and the cause remanded.
ORIGINAL OPINION WITHDRAWN; OPINION SUBSTITUTED; APPLICATION GRANTED; REVERSED AND REMANDED.
HORNSBY, C.J., and ADAMS, KENNEDY and INGRAM, JJ., concur.
MADDOX and HOUSTON, JJ., dissent.
HOUSTON, Justice (dissenting).
This is a contract, not a fraud, action. This is a legal, not an equitable, action. Having read the entire record twice and the briefs more often than that before the original opinion was written, "I am going to leave with the man that brung me" and readopt my original opinion as my dissent:
The plaintiff, Dr. James B. Zickler, appeals from a summary judgment in favor of the defendants, Dr. James N. Jeter, Jr., Dr. Thomas F. Shultz, and Dr. Manuel Eugene Turner, in this action to recover damages for breach of contract. I would affirm.
This action arose out of the sale of Dr. Zickler's anesthesiology practice at Humana Hospital Florence to North Alabama Anesthesiology Group, P.C. ("NAAG"), a professional corporation owned by Drs. Jeter, Shultz, and Turner. The terms of the sale, which were negotiated between Dr. Zickler's attorney, Conrad Pitts, and NAAG's business manager, Steve MacMullin, were initially memorialized by the parties in a "Memorandum of Understanding." That document provided, among other things, that NAAG would pay Dr. Zickler $10,000 for his "contract rights" to practice at the hospital and $215,000, in 60 equal monthly installments of $3,583.33, for his agreement not to practice medicine for five years in competition with NAAG, and that NAAG's payment of the $215,000 would be personally guaranteed by its owners. The "Memorandum of Understanding" contemplated that the terms of the sale would be put in a final contract form. Shortly thereafter, a "Purchase Agreement" was executed by Dr. Zickler and NAAG. The "Purchase Agreement" retained the provision requiring payment of $10,000 for Dr. Zickler's "contract rights"; however, instead of retaining the provision requiring the payment of $215,000 for Dr. Zickler's agreement not to compete, the "Purchase Agreement" incorporated by reference a "Consultation Agreement," which provided that the $215,000 would be paid for Dr. Zickler's agreement to consult with NAAG on certain nonmedical matters. The "Consultation Agreement" provided that Dr. Zickler would not compete with NAAG and further stated that the parties "waived" the legal effect of Ala.Code 1975, § 8-1-1, on the noncompetition agreement. The *921 "Purchase Agreement" also incorporated by reference a "Guaranty Agreement," whereby Drs. Jeter, Shultz, and Turner personally guaranteed payment of NAAG's $215,000 obligation under the "Consultation Agreement."
NAAG paid $10,000 to Dr. Zickler, but later defaulted on its monthly payments. Dr. Zickler sued NAAG, alleging breach of contract, and sued Drs. Jeter, Shultz, and Turner, individually, pursuant to the "Guaranty Agreement." Thereafter, NAAG filed a petition in the United States Bankruptcy Court for the Northern District of Alabama, Northern Division, seeking to reorganize under Chapter 11 of the Bankruptcy Code, 11 U.S.C. § 1101 et seq. The record indicates that Dr. Zickler, through his attorney, was afforded an opportunity to participate as a creditor in the bankruptcy proceeding. The bankruptcy court eventually confirmed a plan of reorganization that specifically discharged NAAG, as well as Dr. Jeter and Dr. Shultz, individually, from any liability to Dr. Zickler in connection with the sale of his practice.[3] Dr. Zickler did not appeal the bankruptcy court's judgment. The trial court subsequently entered a summary judgment for Drs. Jeter, Shultz, and Turner, without stating its reasons for doing so. Dr. Zickler appealed.[4]
Summary judgment was proper in this case if there was no genuine issue of material fact and the defendants were entitled to a judgment as a matter of law. Rule 56, A.R.Civ.P. The burden was on the defendants to make a prima facie showing that no genuine issue of material fact existed and that they were entitled to a judgment as a matter of law. If that showing was made, then the burden shifted to Dr. Zickler to present evidence creating a genuine issue of material fact, so as to avoid the entry of a judgment against him. See Stafford v. Mississippi Valley Title Insurance Co., 569 So.2d 720 (Ala.1990). In determining whether there was a genuine issue of material fact, I must view the evidence in a light most favorable to Dr. Zickler and must resolve all reasonable doubts against the defendants. Because this case was not pending on June 11, 1987, the applicable standard of review is the "substantial evidence" rule. Ala.Code 1975, § 12-21-12. Knight v. Alabama Power Co., 580 So.2d 576 (Ala.1991).
Dr. Zickler contends that the summary judgment was inappropriate because, he says, there were disputed questions of fact as to whether NAAG was guilty of a breach of contract and, if it was, as to whether the defendants were personally liable for that breach under the "Guaranty Agreement."
The defendants contend that they were entitled to a judgment as a matter of law. They argue that the "Consultation Agreement," although incorporated by reference into the "Purchase Agreement," was not actually a part of their agreement with Dr. Zickler. The defendants concede that the "Consultation Agreement" was the result of negotiations between Dr. Zickler's attorney, Conrad Pitts, and their business manager, Steve MacMullin; however, they maintain that they never agreed on behalf of NAAG to pay Dr. Zickler for any consultation services and that they did not authorize MacMullin to enter into such an agreement. The defendants insist that the actual agreement was that NAAG would pay Dr. Zickler $10,000 for his "exclusive" contract rights to practice anesthesiology at Humana Hospital Florence[5] and $215,000 *922 in 60 equal monthly installments for his agreement not to compete with it in the practice of anesthesiology for a period of five years, and that the agreement not to compete, which forms the basis for the claims against them, was void under § 8-1-1, supra. In addition, Dr. Jeter and Dr. Shultz argue that the bankruptcy court's judgment confirming NAAG's plan of reorganization and, thereby, discharging them from any personal liability to Dr. Zickler was res judicata with respect to Dr. Zickler's claims against them based on the "Guaranty Agreement." I agree.
I have carefully reviewed the record in this case, especially the deposition testimony of each of the parties, and I find it clear that there was never a meeting of the minds with respect to the "Consultation Agreement." Dr. Zickler testified that he had no substantive discussions with Conrad Pitts or any representative of NAAG following the execution of the "Memorandum of Understanding." Dr. Zickler further testified that he never expected to consult with NAAG with respect to the items referenced in the "Consultation Agreement"; that he considered the "Consultation Agreement" to be a "formality"; and that he considered the value of any consulting services that he could have provided under the "Consultation Agreement" to be inconsequential. Likewise, the defendants testified that they never agreed on behalf of NAAG to pay Dr. Zickler for any consultation services. The undisputed evidence shows that the true agreement between the parties was as embodied in the "Memorandum of Understanding"; that the "Consultation Agreement" was prepared by Conrad Pitts at the behest of NAAG's business manager, Steve MacMullin, supposedly to provide a tax benefit to NAAG; that although Dr. Zickler and the defendants signed the "Purchase Agreement," they did so without fully understanding why it differed from the "Memorandum of Understanding"; and that all of the parties understood that the $215,000 would, in fact, be paid as consideration for Dr. Zickler's agreement not to practice medicine in competition with NAAG. With the case in this posture, the trial court could have concluded that the "Consultation Agreement," insofar as that agreement provided for the payment of $215,000 to Dr. Zickler for consultation services, was not a material bargained-for provision in the "Purchase Agreement" and that the true agreement between the parties was as reflected in the "Memorandum of Understanding." See Hibbett Sporting Goods, Inc. v. Biernbaum, 375 So.2d 431 (Ala.1979). Consequently, because Dr. Zickler's claims against the defendants were based entirely on their personal guaranties of NAAG's agreement to pay $215,000 for his agreement not to practice in competition with NAAG, the trial court would have been correct in entering the summary judgment for the defendants on the basis of § 8-1-1, supra, which declares that every contract in restraint of a lawful profession, such as the practice of medicine, is void. See Cherry, Bekaert & Holland v. Brown, 582 So.2d 502 (Ala. 1991). I note that the "waiver" that was signed by the parties in an attempt to avoid the legal effect of § 8-1-1 did not save Dr. Zickler's contract claim. It is the established policy of our courts not to aid in the enforcement of a contract expressly prohibited by law. See the cases collected at 5 Ala. Digest Contracts § 136 (1968).
I also note that the trial court could have concluded that the bankruptcy court's judgment confirming NAAG's plan of reorganization was res judicata insofar as Dr. Zickler's claims against Dr. Jeter and Dr. Shultz were concerned and that this would have provided an alternative basis for entering the summary judgment for Dr. Jeter and Dr. Shultz. A valid, final judgment on the merits of an issue extinguishes that issue and operates as an absolute bar in a subsequent suit between the same parties on any issue that was or could have been litigated. Whisman v. Alabama Power Co., 512 So.2d 78 (Ala. 1987). The record indicates that all of the elements of res judicata were satisfied in the present case. *923 Although Dr. Zickler now questions the propriety of the bankruptcy court's discharge of Dr. Jeter and Dr. Shultz under federal bankruptcy law, Dr. Zickler did not appeal the bankruptcy court's judgment, and that judgment is not subject to collateral attack in this case. See Republic Supply Co. v. Shoaf, 815 F.2d 1046 (5th Cir. 1987).
For the foregoing reasons, I would affirm.
MADDOX, J., concurs.
NOTES
[1]  This was a change from the noncompetition provision and was intended to provide ordinary income to the recipient and a deductible business expense to the purchasing doctors. It had a negative effect on Dr. Zickler, because self-employment taxes are payable on payments for consultation.
[2]  The record indicates that Dr. Turner was no longer associated with NAAG at the time the bankruptcy petition was filed and that he was not a party to the bankruptcy proceeding.
[3]  The record indicates that Dr. Turner was no longer associated with NAAG at the time the bankruptcy petition was filed and that he was not a party to the bankruptcy proceeding.
[4]  NAAG is not a party to this appeal.
[5]  The defendants contend that Dr. Zickler represented to them that he had an exclusive contract with the hospital; that he, in fact, had no such contract; that they could have applied for hospital privileges directly from the hospital; and, therefore, that they actually received nothing from Dr. Zickler for their money. Dr. Zickler concedes that he never had an exclusive contract with the hospital and he denies that he ever represented to the defendants that he had such a contract. Dr. Zickler maintains that he was the head of the anesthesiology department at the hospital and that he had been the primary anesthesiologist on staff there for many years; he argues that the defendants, in effect, paid him to leave his practice, thus opening the door for them. Although failure of consideration has been argued by the defendants as a basis for affirming the judgment, I find it unnecessary to reach this issue.
