
942 P.2d 716 (1997)
BALYEAT LAW, P.C., as Trustee, Plaintiff and Appellant,
v.
Linda Jo HATCH, Defendant and Respondent.
No. 97-151.
Supreme Court of Montana.
Submitted on Briefs June 19, 1997.
Decided July 23, 1997.
Regan Whitworth; Balyeat Law Offices, Missoula, for Plaintiff and Appellant.
John M. Morrison; Meloy & Morrison, Helena, for Defendant and Respondent.
*717 LEAPHART, Justice.
Appellant Balyeat Law (Balyeat) appeals from the order of the Ninth Judicial District Court, Teton County, granting respondent Linda Jo Hatch (Hatch) summary judgment on the basis of res judicata. We affirm.
We address the following issue on appeal:
Did the District Court err in granting summary judgment on the basis of res judicata and dismissing Balyeat's complaint for collection of a debt when Balyeat had previously brought an action against Hatch for collection of a debt arising from the same incident?

Factual and Procedural History
Linda Jo Hatch and her son Carson Hatch were injured in a car accident and were subsequently treated at Community Medical Center of Missoula (CMC) periodically between November 10, 1992 and February 4, 1994. On June 13, 1994, Balyeat filed a complaint as trustee for CMC in Missoula Justice Court against Hatch for a debt for services rendered by CMC to Hatch and her son in the amount of $2,400. Default judgment was entered and Hatch paid the debt in full.
On July 28, 1995, Balyeat filed a second complaint against Hatch in Teton County. Balyeat asked for judgment in the amount of $3,612 for goods and services provided to the Hatches by CMC during the same period of time in which CMC provided the services which were the subject of the first debt collection action. The Justice Court granted Hatch summary judgment and dismissed the complaint on the basis of res judicata. The parties stipulated to a de novo review by the Ninth Judicial District Court which likewise dismissed the complaint on the basis of res judicata. Balyeat appeals from that judgment.

Discussion
The standard of review of a summary judgment ruling is de novo. Motarie v. Northern Montana Joint Refuse Disposal Dist. (1995), 274 Mont. 239, 242, 907 P.2d 154, 156; Mead v. M.S.B., Inc. (1994), 264 Mont. 465, 470, 872 P.2d 782, 785. When we review a district court's grant of summary judgment, we apply the same standard as applied by the district court based on Rule 56, M.R.Civ.P. Bruner v. Yellowstone County (1995), 272 Mont. 261, 264, 900 P.2d 901, 903. In Bruner, we set forth our inquiry:
The movant must demonstrate that no genuine issues of material fact exist. Once this has been accomplished, the burden then shifts to the non-moving party to prove, by more than mere denial and speculation, that a genuine issue does exist. Having determined that genuine issues of material fact do not exist, the court must then determine whether the moving party is entitled to judgment as a matter of law. We review the legal determinations made by a district court as to whether the court erred.
Bruner, 900 P.2d at 903 (citations omitted). In the instant case, the parties do not dispute any issues of material fact. Balyeat disputes only the District Court's legal determination that the final judgment in the Missoula County Justice Court matter is res judicata as to the second debt action.
The doctrine of res judicata bars issues and claims litigated in a former action as well as issues and claims which might have been litigated in the former action. Mills v. Lincoln County (1993), 262 Mont. 283, 864 P.2d 1265. This Court has established that the doctrine of res judicata bars a party from relitigating a matter that the party has already had the opportunity to litigate. "`Once there has been a full opportunity to present an issue for judicial decision in a given proceeding ... the determination of the court in that proceeding must be accorded finality as to all issues raised or which fairly could have been raised....'" Mills, 864 P.2d at 1267 (citing First Bank v. District Court (1987), 226 Mont. 515, 519-20, 737 P.2d 1132, 1134-35).
A resolved claim will be res judicata as to subsequent claims if: (1) the parties are the same; (2) the subject matter is the same; (3) the issues are the same and relate to the same subject matter; and (4) the capacities of the persons are the same in reference to the subject matter and issues. Loney v. Milodragovich, Dale & Dye, P.C. (1995), 273 Mont. 506, 510, 905 P.2d 158, 161.
*718 Balyeat argues that res judicata cannot bar its present debt collection action because the subject matter is different from the initial debt collection action in the Missoula County Justice Court. It claims that because the first debt covered medical services and the second debt covers mostly expert testimony costs and the debts had different account numbers, that the subject matter in the two actions is different.
Balyeat relies on Berlin v. Boedecker (1994), 268 Mont. 444, 887 P.2d 1180, as authority for the proposition that separate contracts do not present the same subject matter. By analogy, Balyeat argues that debts with different account numbers do not present the same subject matter. In Berlin, one lawsuit was brought by the Berlins against Boedecker and his company for breach of contract, fraud and breach of fiduciary duties in connection with a contract for acquisition of certain oil and gas leases. Berlin, 887 P.2d at 1184. Berlins brought a second lawsuit against Boedecker and his company for breach of fiduciary duty for failing to reveal conflicts of interest in a different investment transaction. This Court held that the subject matter of the two contracts was not the same for the following reasons:
The contracts in the two actions were separate and the contracts' values differed. The locations of the oil and gas interests in the contracts also differed. Finally, the tortious conduct alleged by appellants in the present action differed from that in the [first action], involving a different fraudulent scheme.
Berlin, 887 P.2d at 1185.
We agree with Hatch that Berlin is distinguishable. In contrast to Berlin, the first and second actions brought by Balyeat both involve whether and to what extent Hatch is liable to Balyeat for services provided by CMC. The services in question were provided in connection with one car accident. The services giving rise to both debt collection actions were rendered in the same time period and CMC was aware of the entire debt at the time of the first action. For the above reasons, we hold that the subject matter of the two actions is the same.
The remaining requirements for res judicata have also been met. The parties in this action are the same as the parties in the Missoula County Justice Court action. The issue in this matter, whether Hatch owes amounts claimed due, is the same as the issue in the previous action and, as we have said, relates to the same subject matter. The capacities of the persons in this action are the same as the capacities of the identical persons in the previous action: Balyeat, as assignee/trustee for CMC, claims Hatch, as an individual, is indebted to it for medical services provided by its assignor to Hatch.
Furthermore, the doctrine of res judicata bars not only subsequent litigation of previously litigated subject matter and issues, but also litigation of subject matters and issues which could have been litigated in the prior proceeding. Loney, 905 P.2d at 161. No evidence was presented showing that Balyeat lacked the opportunity to litigate all claims incurred by CMC during the period from November 10, 1992 to February 4, 1994, for services provided to the Hatches when Balyeat commenced its Missoula County Justice Court action in June, 1994.
Accordingly, we conclude that Balyeat's second debt collection action is barred by res judicata. Affirmed.
TURNAGE, C.J., and GRAY, NELSON and REGNIER, JJ., concur.
