
765 So.2d 251 (2000)
STATE STREET BANK AND TRUST COMPANY, as Trustee, Appellant,
v.
Jubran A. BADRA and Emily G. Badra, his wife; Monarch Country Club Homeowners Association, Inc.; Martin Downs Property Owners Association, Inc.; Unknown Parties In Possession, Appellees.
No. 4D99-0818.
District Court of Appeal of Florida, Fourth District.
August 9, 2000.
*252 Damon M. Ellis and Mark Broderick of Echevarria & Associates, P.A., Tampa, for appellant.
Joseph L. Mannikko, E. Barbara Baris and Brent E. Baris of Mannikko & Baris, Palm City, for Appellees-Jubran A. Badra and Emily G. Badra, his wife.
SHAHOOD, J.
We reverse final summary judgment entered in favor of appellees, Jubran and Emily Badra, holding that the trial court erred in barring appellant's claim based on the doctrine of res judicata and collateral estoppel.
On September 16, 1988, the Badras executed and delivered to Amerifirst Bank a promissory note and purchase money mortgage in the amount of $320,000.00. On October 1, 1991, the promissory note was assigned to State Street Bank and Trust Company (State Street Bank), as Trustee, through the Resolution Trust Corporation. Under the terms of the promissory note, the Badras were to repay the principal at a specified interest rate on the first of each month. The original note was lost on October 1, 1991, when the Resolution Trust Corporation transferred the mortgage and note to State Street Bank.
The Badras failed to make payment on February 1, 1993 and any subsequent payments. As such, a principal balance of $302,024.53 was due and owing.
Under the terms of the mortgage, the lender was to give notice to the borrower prior to acceleration following the borrower's breach of any covenant or agreement in the security instrument. The notice was to specify: (a) the default; (b) the action required to cure the default; (c) a date, not less than 30 days from the date the notice is given to the borrower, by which the default must be cured; and (d) that the failure to cure the default on or before the date specified in the notice may result in acceleration of the sums secured by the security instrument, foreclosure by judicial proceeding and sale of the property. If the default is not cured by the date specified in the notice, the lender, at its option, may require immediate payment in full of all monies secured by the security instrument without further demand and may foreclose on the security instrument by judicial proceeding.
In 1993, State Street Bank filed an action to foreclose on its mortgage in the amount of $305,024.53. On February 12, 1997, the action was tried. During trial, the trial court addressed the issue as to whether all conditions precedent to the initiation of the foreclosure action had been complied with. The Badras argued that in order to accelerate payment under the terms of the mortgage, notice had to be mailed to the borrowers at the property address or any other address designated by the borrower. Instead notices dated *253 December 15, 1992 and March 22, 1993 were sent to incorrect addresses, and thus, were never received by the borrowers. Because of State Street Bank's failure to meet its burden of proof with regard to the conditions precedent under the mortgage, the trial court granted the Badras' motion for judgment on the pleadings. The Final Judgment dated March 20, 1997, stated:
This action was tried before the Court on February 12, 1997. On the evidence presented, the Court incorporating the factual findings made on the record, finding plaintiff failed to meet its burden of proof, it is adjudged that Plaintiff, State Street Bank and Trust Company, as Trustee, take nothing by this action and that Defendants, Jubran A. Badra and Emily Badra, go hence without day.
This matter was never appealed by State Street Bank. Instead, on February 18, 1997, six days after the trial court's ruling, a notice of acceleration, properly addressed, was sent to the Badras by State street Bank. On January 23, 1998, State Street Bank filed an identical complaint for foreclosure against the Badras for $305,024.53. The Badras filed a motion for partial summary judgment based on the doctrines of res judicata and collateral estoppel.
At the hearing on the Badras' motion, the trial court granted summary judgment but stated that it was not declaring a forfeiture of the mortgage. In its Final Summary Judgment in favor of the Badras, the trial court stated that it reviewed the transcript in the first foreclosure action and concluded that State Street Bank was not prepared to litigate the issues at trial, but proceeded to do so anyway, resulting in its loss. Further, the court held that the bank did nothing to protect itself against judgment in the first case.
In order for the doctrine of res judicata to bar a subsequent suit, the following four identities must be present: 1) identity of the thing sued for; 2) identity of the cause of action; 3) identity of persons and parties; and 4) identity of the quality or capacity of the persons for or against whom the claim is made. See State of Wisconsin v. Martorella, 670 So.2d 1161, 1162 (Fla. 4th DCA 1996); Youngblood v. Taylor, 89 So.2d 503, 505 (Fla.1956)(res judicata bars not only later suits on the same causes of action, but also matters that "could have been raised"; the test of identity of cause of action is "identity of the facts essential to the maintenance of the actions").
In addition to the four identities necessary to establish res judicata, under Martorella, the party claiming the benefit of the former adjudication has the burden of establishing, with sufficient certainty by the record or by extrinsic evidence, that the matter was formerly adjudicated. See Martorella, 670 So.2d at 1162. Finally, the doctrine of res judicata will not be invoked where it will work an injustice. See deCancino v. Eastern Airlines, Inc., 283 So.2d 97 (Fla.1973).
In this case, we hold that the second action was not barred by res judicata because "identity of the cause of action" had not been met and there had been no adjudication on the merits.
In Florida, the test for deciding whether there is identity of causes of action rests upon a comparison of the facts constituting the underlying transaction. See Variety Children's Hosp. v. Mt. Sinai Hosp. of Greater Miami, Inc., 448 So.2d 546, 547 (Fla. 3d DCA), review denied, 458 So.2d 274 (Fla.1984); see also Gordon v. Gordon, 59 So.2d 40, 44 (Fla.1952)(the test for identity of causes of action for purpose of determining res judicata is identity of facts essential to the maintenance of the actions). Res judicata extends only to the facts and conditions as they existed at the time the judgment was rendered, at the time the issues in the first action were made, and to the legal rights and relations of the parties as fixed by the facts determined by that judgment. See Hialeah Race Course, Inc. v. Gulfstream Park Racing Ass'n, 210 So.2d 750, 753 (Fla. 4th *254 DCA 1968). When other facts or conditions intervene before the second suit, furnishing a new basis for the claims and defenses of the respective parties, the issues are no longer the same and the former judgment cannot be pleaded in bar of the second action. See id. at 754. The applicability of the doctrine in each case turns on the particular facts alleged in each action and the particular disposition of the allegations in the first action. See id.
While the two complaints filed by State Street Bank in the first and second actions were identical, the notices of acceleration, differed significantly between the two cases. The first action relied upon notices of acceleration dated December 15, 1992 and March 22, 1993 and the instant action relied upon a notice of acceleration dated February 18, 1997, after the conclusion of the first action.
In the first action, the two notices of acceleration sent to the Badras were sent to an incorrect address. More importantly, the December 15, 1992 notice of acceleration stated that as of that date, the Badras were two installments in arrears and owed $7,866.60. The March 22, 1993 notice stated that as of that date, the Badras owed $8,510.70. Both notices were sent by National Mortgage Company.
In the second action, the notice of acceleration sent to the Badras was sent to the correct address and stated that the Badras were 49 payments in arrears and owed a total amount of $180,499.56. This notice was sent by Boatmen's National Mortgage, Inc.
The trial court, in the first action, held that State Street Bank relied upon notices of acceleration that were insufficient to satisfy its burden of proof with regard to the conditions precedent under the mortgage. Since the first and second actions involved different notices of acceleration and such letters were essential to the maintenance of each action, there existed essential facts between the two cases which differed.
The Final Judgment in the first action was not an adjudication on the merits. The party claiming the benefit of the former adjudication has the burden of establishing, with sufficient certainty by the record or by extrinsic evidence, that the matter was formerly adjudicated. See Martorella, 670 So.2d at 1162. The doctrine of res judicata has no applicability where there was no adjudication on the merits in the first suit and where the relief sought in the second suit was not the same relief sought in the first suit. See Swinney v. City of Tampa, 707 So.2d 765, 766 (Fla. 2d DCA 1998); see also Suniland Assocs., Ltd. v. Wilbenka, Inc., 656 So.2d 1356, 1358 (Fla. 3d DCA 1995)(For res judicata or collateral estoppel to apply, there must also exist in the prior litigation a "clear-cut former adjudication" on the merits.). A judgment rendered on any grounds which do not involve the merits of the action may not be used as the basis for the operation of the doctrine of res judicata. See Allbright v. Hanft, 333 So.2d 112, 114 (Fla. 2d DCA 1976). As to whether there has been an adjudication on the merits, this court has held that in order for the doctrine of res judicata to apply, the same parties and issues must be before the court and a full hearing on the issues must be granted with a final determination on the issues. See Chandler v. Chandler, 226 So.2d 697, 699 (Fla. 4th DCA 1969).
The trial court in the first action granted the Badras' motion for judgment on the pleadings because State Street Bank "failed to meet its burden of proof "with regard to the conditions precedent under the mortgage." Thus, by failing to comply with certain conditions precedent, State Street Bank took nothing by that action.
In Tampa Pipeline Transport Co. v. IMC Fertilizer, Inc., 614 So.2d 675 (Fla. 2d DCA 1993), the Second District held that where a trial court's order granting motions for summary judgment and judgment on the pleadings did not specify the grounds upon which it relied, it was unclear *255 whether the trial court intended the final judgment to be an adjudication on the merits or whether it found that the action was merely premature. Because the conditions precedent of the contract were not complied with by appellant, the appellate court concluded that the trial court could only have determined that the action was premature. Therefore, the final judgment did not act as an adjudication on the merits.
Unlike Tampa Pipeline, the trial court in this case clearly delineated the basis for granting judgment on the pleadings, that is, that State Street Bank did not comply with conditions precedent under the mortgage. Under the terms of the mortgage, prior to acceleration of mortgage, the lender shall give notice to the borrower of the default, the action required to cure the default, a date in which the default must be cured and that the failure to cure the default could result in an acceleration of sums due under the mortgage. Because of the trial court's specified grounds for granting judgment on the pleadings, we conclude that the trial court determined that the action was premature. Thus, the final judgment did not act as an adjudication on the merits. At no time did the court grant summary judgment on the basis that the mortgage was unenforceable.
We also hold without further discussion that the trial court erred in granting summary judgment based on the doctrine of collateral estoppel. See Stogniew v. McQueen, 656 So.2d 917, 919 (Fla.1995); University Hosp., Ltd. v. State, Agency for Health Care Admin., 697 So.2d 909, 911 (Fla. 1st DCA 1997); and Hittel v. Rosenhagen, 492 So.2d 1086, 1089 (Fla. 4th DCA 1986).
REVERSED AND REMANDED.
GUNTHER and GROSS, JJ., concur.
