
317 So.2d 857 (1975)
ECOLOGICAL SCIENCE CORPORATION, a Florida Corporation, F/K/a Southern Gulf Utilities, Inc., Appellant,
v.
BOCA CIEGA SANITARY DISTRICT and the Board of County Commissioners of Pinellas County, As Its Governing Body, Appellees.
No. 74-1079.
District Court of Appeal of Florida, Second District.
August 8, 1975.
*858 Paul C. Huck of Aurell & Huck, Miami, and Harrison, Greene, Mann, Davenport, Rowe & Stanton, St. Petersburg, for appellant.
Daniel N. Martin of Delzer, Edwards & Martin, Port Richey, and Adrian S. Bacon, of Bacon & Hanley, St. Petersburg, for appellees.
BOARDMAN, Judge.
The parties to this instant appeal have previously been before us. A prior suit was filed by the appellant against the appellees in 1966 for breach of contract. Appellant was the general contractor for the construction of a sanitary sewer system built for the appellees. The trial court granted a summary judgment against appellant as to Counts II and III. This court reversed the summary judgment in Southern Gulf Utilities, Inc. v. Boca Ciega Sanitary District, Fla.App.2d, 1970, 238 So.2d 458, cert. den. Fla. 1970, 240 So.2d 813.
Upon remand, appellant sought leave of the trial court to amend its complaint and to file supplemental pleadings to include a claim allegedly arising subsequent to the filing of the suit. The trial court, after hearing, denied the motion assigning as grounds that it was "... of the opinion that too much time has elapsed and the issue have been framed for such a period of time that it is now inappropriate to bring into the controversy an additional cause of action... ." In view of the trial court's ruling appellant then filed the present action. In response, appellees filed a motion to consolidate the two suits and a motion to dismiss based on the following defenses, to wit: election of remedies, splitting a cause of action and res judicata. The hearing on the said motions was conducted by a judge other than the judge *859 who presided over the first suit. Counsel for appellees urged that the initial judge, who was thoroughly familiar with the case and the issues involved, should hear all matters. Counsel for appellant, on the other hand, was satisfied that the second judge should rule on whether a motion to dismiss was the proper vehicle in which to raise the above defenses. The trial court, after hearing, granted the motion to dismiss with leave to amend. Appellant chose not to amend and final judgment was entered. This timely appeal followed from that final judgment.
Appellant has raised several points on this appeal. The first is whether appellees could properly raise the defenses of election of remedies, splitting a cause of action and res judicata in its motion to dismiss.
Affirmative defenses are covered by Rule 1.110(d), RCP, which requires a party in its pleading to set forth "... affirmatively ... res judicata ... and any other matter constituting an avoidance or affirmative defense." The defenses known as election of remedies and splitting a cause of action are certainly within the scope of the aforementioned rule and, therefore, constitute affirmative defenses.
Under a prior rule it was held that affirmative defenses could not be raised by a motion to dismiss. Volpicella v. Volpicella, Fla.App.2d, 1962, 136 So.2d 231; Hough v. Menses, Fla. 1957, 95 So.2d 410. Subsequent to these decisions the following sentence was added to Rule 1.110(d), RCP:
"... Affirmative defenses appearing on the face of a prior pleading may be asserted as grounds for a motion or defense under Rule 1.140(b); provided this shall not limit amendments under Rule 1.190 even if such ground is sustained."
This amendment provides no comfort to appellees for the reason that these affirmative defenses do not appear on the face of the complaint. Therefore, the exception, as provided in Rule 1.110(d), RCP, cannot be successfully relied upon. See Stern v. First National Bank of South Miami, Fla.App.3d, 1973, 275 So.2d 58. The court is bound by and must confine itself solely to the allegations within the four corners of the complaint. See Pizzi v. Central Bank and Trust Company, Fla. 1971, 250 So.2d 895.
Appellant's remaining points are addressed to each of the above mentioned affirmative defenses. Since we have reversed on point I, it is not necessary to comment on the remaining issues. However, since this controversy has been pending for an inordinate length of time and our record includes the file in the other case, we think it advisable to discuss the merits of these defenses.
In the original complaint, the appellant was suing for damages resulting from the appellees' alleged failure to provide certain easements and for their alleged failure to acknowledge or pay for certain extras over the original contract price performed by appellant. The new complaint sought final payment of the remainder of the contract price. The original complaint was filed on July 29, 1966. The new complaint alleges that the appellees became obligated to pay the balance of the contract price on March 7, 1967. Thus, it appears that even though the first complaint contains the allegations that appellant had substantially completed the contract, its claim for the balance of the contract price had not even matured at the time of filing of that complaint. Appellees' contention that appellant should have asserted the claim for the final payment in its first suit is without merit, because appellant attempted to do just that but was prevented from doing so by the court's order in the first case. Accordingly, these affirmative defenses do not appear sufficient to negate the cause of action alleged in the second suit. Any risk of duplication of claims could be avoided by a consolidation of the two suits.
*860 For the above reasons the portion of the order dated August 14, 1974, directing that the motion to dismiss be granted is hereby reversed and the cause is remanded to the circuit court in compliance with the provisions of said order reassigning this cause to the Honorable C. Richard Leavengood, the presiding judge in the first case, and for further proceedings consistent with this opinion.
Reversed and remanded.
HOBSON, Acting C.J., and GRIMES, J., concur.
