
394 S.E.2d 263 (1990)
100 N.C. App. 70
The COUNTY OF RUTHERFORD By and Through its CHILD SUPPORT ENFORCEMENT AGENCY, ex rel. Pamela Marie Watson HEDRICK
v.
Melvin Verno WHITENER, II.
No. 8929DC1147.
Court of Appeals of North Carolina.
August 7, 1990.
*264 Hamrick, Bowen, Nanney & Dalton by Robert L. Mebane, Rutherfordton, for plaintiff-appellant.
Robert L. Harris, Rutherfordton, for defendant-appellee.
GREENE, Judge.
The County of Rutherford by and through its Child Support Enforcement Agency, ex rel. Pamela Marie Watson Hedrick (County) appeals from summary judgment entered for the defendant.
In this civil action, the County, which administered the "Child Support Enforcement Program," sought to establish the defendant as the natural father of a child of Pamela Marie Watson Hedrick (mother). Mother had been receiving public assistance on behalf of her child from the County of Rutherford. The County also sought reimbursement from the defendant for "all past public assistance paid for or on behalf of the Defendant's minor child," and that the defendant be ordered to provide reasonable child support in the future. The County requested that the Clerk of Superior Court of Rutherford County be named as "designated payee for any and all child support payments received in this action and that the clerk be directed to transmit all child support payments received in this action to the North Carolina Department of Human Resources...." The defendant filed an answer which, in addition to denying the material allegations in the complaint, requested that the complaint be dismissed for failure to state a claim "pursuant to Rule 12(b)(6) of the North Carolina Rules of Civil Procedure."
When the County's claim came on for trial, the trial court accepted evidence outside the pleadings, treating the motion to dismiss as one for summary judgment. The evidence accepted outside the pleadings was reflected in one of the findings of fact entered by the trial court, which finding is undisputedly supported by the evidence. Specifically, the court found as a fact:
That the Defendant, Melvin Verno Whitener, II, was prosecuted by the State of North Carolina through its attorney, Harold Caviness in the Superior Court of Rutherford County on March 8, 1988 in case number 85 CRS 7598 wherein Defendant was found not to be the father of [the child] born of the body of Pamela Marie Watson Hedrick on December 17, 1984 by a Jury Verdict rendered before the Honorable Chase B. Saunders and that the Superior Court of Rutherford County had proper jurisdiction of the case number 85 CRS 7598 Noves.

The court then concluded:
1. That the Plaintiff in this action is in privity with the State of North Carolina in the Rutherford County Superior Court Case No. 85 CRS 7598.
......
2. That the Doctrine of Res Judicata is applicable to this present action in that it would Bar relitigation of the issue of paternity which was raised in a prior proceeding involving the same parties.
Based on relevant findings and conclusions of law, the trial court granted summary judgment for the defendant and dismissed the complaint.
The issues presented are: (I) whether the failure of the defendant to plead res judicata is a bar to that issue being raised at hearing on summary judgment; and (II) whether a county which administers the "Child Support Enforcement Program" may seek, in a civil action, reimbursement from an individual for public assistance paid on behalf of a child, when that individual was adjudicated not to be the father of the child in a prior criminal action.

I
County argues that the summary judgment must be vacated because res judicata on which the judgment was based was not affirmatively pled either in the answer or in the motion to dismiss. We disagree.
Rule 8(c) of our Rules of Civil Procedure provides that res judicata is an affirmative defense and must be set forth *265 affirmatively in the pleadings. N.C.G.S. § 1A-1, Rule 8(c) (1983). Nonetheless, our courts have held that where "responsive pleadings are not yet due" a party may raise an affirmative defense in a motion for summary judgment. Dickens v. Puryear, 302 N.C. 437, 442, 276 S.E.2d 325, 329 (1981). Dickens did not address the question of whether a party may assert an affirmative defense in a summary judgment motion after filing an answer in which no affirmative defense was alleged. There is a split of authority in the federal courts as to whether defendant should be allowed in this instance to assert the affirmative defense. See 2A J. Moore, Moore's Federal Practice § 8.28, at 8-206-07 (2d ed. 1990). To avoid a decision based on a pleading technicality, we now hold that "absent prejudice to plaintiff, an affirmative defense may be raised by a motion for summary judgment regardless of whether it was pleaded in the answer or not." Id., at 8-207.
Nevertheless, as noted in Dickens, an affirmative defense sought to be raised for the first time in a motion for summary judgment "must ordinarily refer expressly to the affirmative defense relied upon." 302 N.C. at 443, 276 S.E.2d at 329. In the absence of an expressed reference in the motion for summary judgment, if the "affirmative defense was clearly before the trial court," the failure to expressly mention the defense in the motion will not bar the trial court from granting the motion on that ground. Id., at 443, 276 S.E.2d at 330. Furthermore, where a motion for summary judgment is supported by matters outside the pleadings, the pleadings are deemed amended if in fact the issue not raised by the pleadings or by the motion for summary judgment is tried by the express or implied consent of both parties. N.C.G.S. § 1A-1, Rule 15(b) (1983); see also Baker v. Chicago Fire & Burglary Detection, Inc., 489 F.2d 953, 955 n. 3 (1973).
Here, neither the defendant's answer nor the motion to dismiss made any reference to the defense of res judicata. However, the record is clear that evidence was before the trial court that the defendant had been tried previously in the criminal courts of Rutherford County and had been adjudicated not to be the father of the child. Introduction of this evidence at the hearing on summary judgment indicates that the affirmative defense of res judicata was clearly before the trial court with the consent of both parties and the pleadings are deemed amended.

II
The doctrine of res judicata has two aspects: claim preclusion and issue preclusion. Claim preclusion which precludes relitigation of claims is more generally referred to as res judicata. Issue preclusion, which "preclude[s] the parties or their privies in a former action from relitigating in a subsequent action issues necessarily determined in the former action," is more generally referred to as collateral estoppel. State By and Through New Bern C.S.A. v. Lewis, 311 N.C. 727, 730, 319 S.E.2d 145, 148 (1984); see generally 46 Am.Jur.2d Judgments §§ 396 and 397 (1969).
Here, since a civil action filed by the County against the defendant is not an attempt to relitigate the same claim litigated in the previous action, this appeal presents a question of collateral estoppel, not res judicata. The defendant argues that the County is collaterally estopped from relitigating the issue of paternity since that issue was previously determined in favor of the defendant in the prior criminal action. For the defendant to prevail in his argument, two elements must exist:
(1) The issue of paternity must necessarily have been determined previously and (2) the parties to that prior action must be identical or privies to the parties in the instant case.

Lewis, 311 N.C. at 731, 319 S.E.2d at 148.
In the present case, it is undisputed that the issue of paternity necessarily was determined in the prior criminal action because in that case the jury specifically answered on the verdict form that the defendant was not the father of the child in question. Furthermore, it is equally clear that while the defendants in both the criminal and civil actions are the same, the plaintiffs are not. In the first action the plaintiff *266 was the State of North Carolina and in this action the plaintiff is the County of Rutherford.
The defendant argues that the facts presented in Lewis cannot be distinguished from the facts in this case and that accordingly the County is bound by the determination of paternity in the prior criminal action. We disagree.
In Lewis, the State of North Carolina was administering the Child Support Enforcement Program for Carteret County. See generally N.C.G.S. §§ 110-128 through 110-141 (1988). The State "by and through its New Bern Child Support Agency" filed an action seeking indemnification for public assistance paid on behalf of the children. The trial court held that the defendant was estopped from denying paternity of the children in question because of a prior criminal conviction for willful neglect of and refusal to support the children. Lewis, 311 N.C. at 729, 319 S.E.2d at 147. The Lewis Court held:
The state herein is the same party which challenged defendant in the prior suit, pursuing its same financial interest in securing support payments by a parent for his children in both actions.
Id., at 734, 319 S.E.2d at 150. The Court then concluded that since the issue of defendant's paternity necessarily had been determined in the prior criminal action, collateral estoppel applied. Id.
Here we are not presented, as in Lewis, with the same parties. The question is whether the State of North Carolina, who prosecuted the criminal non-support action, and the County, who now seeks reimbursement in a civil action for public assistance paid, are in privity. Generally, "such privity involves a person so identified in interest with another that he represents the same legal right." 46 Am.Jur.2d Judgments § 532. "Privity is not established, however, from the mere fact that persons may happen to be interested in the same question or in proving or disproving the same state of facts, or because the question litigated was one which might affect such other person's liability as a judicial precedent in a subsequent action." 46 Am. Jur.2d, at 685-86.
The term "privy" when applied to a judgment or a decree refers to one whose interest has been legally represented at the trial.... A trial in which one party contests his claim against another should be held to estop a third person only when it is realistic to say that the third person was fully protected in the first trial. There can be no such privity between persons as to produce collateral estoppel unless the result can be defended on principles of fundamental fairness and the due process sense.
46 Am.Jur.2d, at 686.
Here, the State and County were interested in proving the same state of facts: that the defendant was the child's father. However, the County had no control over the previous criminal litigation, and nothing in the record indicates that the interest of the County was legally represented in the criminal trial. Furthermore, we are unable to distinguish the present case from the facts presented in Tidwell v. Booker, 290 N.C. 98, 225 S.E.2d 816 (1976) and Settle v. Beasley, 309 N.C. 616, 308 S.E.2d 288 (1983). In Tidwell, the Court held there was no privity between the State who instituted a criminal action for non-support and the mother who later instituted a civil action for non-support. In Settle, the Court held there was no privity between the Child Support Enforcement Agency of Johnston County, who in a civil action sought indemnification for public assistance paid, and a child, who through his guardian ad litem sought support through a subsequent civil suit.
Accordingly, the trial court erred in concluding that the County was in privity with the State of North Carolina, and thus the doctrine of collateral estoppel does not bar the County's action against this defendant in its effort to seek reimbursement for public assistance paid.
Reversed.
ORR and LEWIS, JJ., concur.
