
588 So.2d 868 (1991)
Ex parte STATE of Alabama ex rel. Sheeley A. HARRELL.
(Re STATE of Alabama ex rel. Sheeley A. HARRELL v. James E. HARRELL).
1901394.
Supreme Court of Alabama.
October 11, 1991.
William Prendergast, Lois Brasfield and Mary E. Pons, Asst. Attys. Gen., for petitioner.
E. Paul Jones, Alexander City, for respondent.
INGRAM, Justice.
The State of Alabama sought a writ of mandamus directing the Juvenile Court of Coosa County to withdraw its order granting James E. Harrell's request for a blood test made pursuant to his motion to determine paternity. The Court of Civil Appeals denied the State's petition for the writ of mandamus, and we granted the State's petition for the writ of certiorari.
The facts, as set forth in the State's petition, reveal that James E. Harrell and Sheeley A. Harrell were married in 1986. In 1987, Sheeley ("the mother") gave birth to a male child. In 1988, James and the mother separated, and the mother began receiving Aid to Families with Dependent Children ("AFDC") benefits. Thereafter, the State filed a petition for support, alleging that James had a duty to support the minor child.
In response to the petition for support, James signed an answer and waiver, admitting all of the allegations contained in the *869 petition. At the same time, he entered into a support agreement, acknowledging that he was the parent of the child and that he had a duty to support the child. The answer and waiver and the support agreement were filed in the Juvenile Court of Coosa County. Thereafter, that court issued an order, finding James to be the parent of the minor child. However, because James and the mother had reconciled by the time the juvenile court issued its order, no child support was ordered. No appeal was taken from that order.
In December 1990, the State filed a modification petition for support against James, seeking current child support for the minor child because James was no longer living in the marital home. However, in his answer to the modification petition, James denied the allegations contained in the petition and alleged that he had reason to believe that he was not the father of the minor child, although the reasons for this belief were not stated in the answer.
At the time he filed his answer to the modification petition, James also filed a motion to determine paternity, asking for a blood test. The only ground stated by James in his motion was that he had reason to believe that he was not the father of the minor child.
The State filed a motion in opposition to the blood test and included as grounds the fact that the parties were married at the time of the minor child's birth and that James had previously entered into a support agreement that was incorporated into the juvenile court's order. The State asserted that the issue of paternity was res judicata. Following a hearing on the motions filed by both parties, the juvenile court issued an order for blood testing.
The issue presented is whether the Court of Civil Appeals erred in denying a writ of mandamus directing the juvenile court to withdraw its order granting blood testing and to deny James's motion to determine paternity.
Initially, we note that mandamus is a drastic and extraordinary writ to be issued only where there is: (1) a clear legal right in the petitioner to the order sought; (2) an imperative duty upon the respondent to perform, accompanied by a refusal to do so; (3) the lack of another adequate remedy; and (4) properly invoked jurisdiction of the court. Barber v. Covington County Comm'n, 466 So.2d 945 (Ala.1985). Furthermore, we note that it is a well-settled principle that once there has been a judicial determination of paternity, parties are precluded from disputing the paternity in subsequent proceedings. See, e.g., Julian v. Julian, 402 So.2d 1025 (Ala.Civ.App.1981); Stewart v. Stewart, 392 So.2d 1194 (Ala. Civ.App.1980).
In this case, paternity was established in a prior order of the juvenile court. The order stated that "the court is of the opinion and finds that the defendant is the parent of said minor child and is obligated to pay support for the minor child." This language clearly establishes a finding of paternity with regard to support of the child. Because of the prior order determining paternity, we hold that James is barred, under the doctrine of res judicata, from challenging the paternity of the child for purposes of child support.
The elements of res judicata are: the same parties, the same subject matter, and a judgment on the merits by a court of competent jurisdiction. First State Bank of Altoona v. Bass, 418 So.2d 865 (Ala. 1982). Once these elements are met, the former judgment becomes an absolute bar to any subsequent suit on the same cause of action. Dominex, Inc. v. Key, 456 So.2d 1047 (Ala.1984).
In this case, there is no question that the elements of res judicata have been met. The same parties are disputing the same subject matter under the same facts that were presented in the prior support proceeding. In that prior proceeding, there was a judgment on the merits by a court of competent jurisdiction. Therefore, we hold that James is not entitled to challenge the child's paternity for purposes of child support.
While we acknowledge that the Court of Civil Appeals has, in rare instances, allowed paternity to be challenged through a *870 motion made pursuant to Rule 60(b), A.R.Civ.P., the father's motion in this case was not a Rule 60(b) motion. See, e.g., Coburn v. Coburn, 474 So.2d 728 (Ala.Civ. App.1985). Furthermore, the father has shown nothing to indicate that he is entitled to the extraordinary relief available through a Rule 60(b) motion.
Because we conclude that James is barred from challenging paternity for purposes of child support, because of the applicability of the doctrine of res judicata, we hold that the State's petition for the writ of mandamus is due to be granted. The judgment of the Court of Civil Appeals is due to be reversed and the cause remanded with instructions to grant the writ of mandamus directing the Juvenile Court of Coosa County to withdraw its order granting blood testing in this case and to deny the motion to determine paternity.
REVERSED AND REMANDED WITH INSTRUCTIONS.
HORNSBY, C.J., and MADDOX, ALMON, SHORES, ADAMS, HOUSTON, STEAGALL and KENNEDY, JJ., concur.
