In this mortgage foreclosure action, the Court granted Carolina First Bank’s (“the Bank”) petition for a writ of certiorari to review the Court of Appeals’ decision in Carolina First Bank v. BADD, L.L.C., 400 S.C. 343, 733 S.E.2d 619 (Ct.App.2012), which held William McKown1 is entitled to a jury trial. We disagree and therefore reverse the decision of the Court of Appeals.
Procedural History
BADD, L.L.C. (“BADD”), purchased three warehouse units in Myrtle Beach. To finance the transaction, BADD executed two promissory notes. A personal guaranty was also executed by McKown, who was a member of BADD. After BADD defaulted, the Bank brought this foreclosure action and included McKown as a party pursuant to S.C.Code Ann. § 29-3-660 (2007) based on his status as a guarantor.
In McKown’s amended answer and counterclaim, he demanded a jury trial because the Bank sought a money judgment for the breach of a guaranty arrangement. McKown *292further sought an accounting and a determination that the guaranty agreement was unconscionable. McKown then asserted two counterclaims — (1) civil conspiracy and (2) breach of contract — both based on an alleged conspiracy between the Bank and William Rempher. Finally, McKown asserted third-party claims against Rempher.2
The Bank moved for an order of reference. The circuit granted the motion, referring the matter in its entirety to the master-in-equity.
The Court of Appeals reversed, holding McKown was entitled to a jury trial because the Bank’s claim on the guaranty agreement was a separate and distinct legal claim.3 Carolina First Bank, 400 S.C. at 347, 733 S.E.2d at 620.
We granted the Bank’s petition for a writ of certiorari to review the Court of Appeals’ decision.
Issue Presented
Did the Court of Appeals err in finding McKown was entitled to a jury trial?
Standard of Review
Whether a party is entitled to a jury trial is a question of law, which this Court reviews de novo, owing no deference to the Court of Appeals’ decision. See Wachovia Bank, Nat. Ass’n v. Blackburn, 407 S.C. 321, 328, 755 S.E.2d 437, 441 (2014).
Law/Analysis
The Court of Appeals held that when a lender exercises its statutory right to join a guarantor as a party to a foreclosure *293action in order to seek a deficiency judgment, the guarantor has a right to a jury trial. The Bank contends this was error. We agree.
I. Guarantor’s Right To A Jury Trial When A Bank Seeks A Deficiency Judgment Pursuant to § 29-3-660.
The South Carolina Constitution provides that the right to a jury trial shall be preserved inviolate. S.C. Const, art. I, § 14. Whether a party is entitled to a trial by jury depends on whether the right to a jury was secured at the time of the adoption of our state constitution. Mims Amusement Co. v. S.C. Law Enforcement Div., 366 S.C. 141, 150, 621 S.E.2d 344, 348 (2005) (“The right to a trial by jury is guaranteed in every case in which the right to a jury was secured at the time of the adoption of the Constitution in 1868.”). “Generally, the relevant question in determining the right to a trial by jury is whether the action is legal or equitable.” Lester v. Dawson, 327 S.C. 263, 267, 491 S.E.2d 240, 242 (1997). Because a foreclosure action is one sounding in equity, a party is not entitled, as a matter of right, to a jury trial. Wachovia Bank, Nat. Ass’n v. Blackburn, 407 S.C. 321, 328, 755 S.E.2d 437, 441 (2014).
McKown was joined as a party to the foreclosure action pursuant to S.C.Code Ann. § 29-3-660 (2007). Section 29-3-660 provides:
In actions to foreclose mortgages ... if the mortgage debt be secured by the covenant or obligation of any person other than the mortgagor the plaintiff may make such person a party to the action and the court may adjudge payment of the residue of such debt remaining unsatisfied after a sale of the mortgaged premises against such other person and may enforce such judgment as in other cases.
(Emphasis supplied). This statute is derived, in part, from the Act of 1791, which vests exclusive jurisdiction in courts of equity for foreclosure actions. See, e.g., Williams v. Beard, 1 S.C. 309, 324 (1870) (discussing the Act of 1791 and the role it played in vesting courts of equity with jurisdiction to decide mortgage-related disputes). The power to render a deficiency judgment is included within the jurisdiction of courts of equity. *294See Perpetual Bldg. & Loan Ass’n of Anderson v. Braun, 270 S.C. 338, 342, 242 S.E.2d 407, 409 (1978) (recognizing that a deficiency judgment is incidental to the relief sought in a foreclosure action and that the Act of 1791 integrated the two for purposes of characterizing the action as equitable); see also 27 S.C. Jur. Mortgages § 103 (1996) (“Mortgage foreclosures are partly in rem ... and partly in personam ...; however, the strict distinction between such designations was abandoned by the Act of 1791.... The court’s in personam jurisdiction to enter a deficiency judgment does not alter the equitable character of the [foreclosure] action.”).
Here, it is clear the Bank included McKown as a party to its foreclosure action only for the purpose of collecting a deficiency should one be adjudged. The Bank’s action does not alter the equitable character of the action. See Perpetual Bldg. & Loan Ass’n of Anderson, 270 S.C. at 342, 242 S.E.2d at 409. Likewise, § 29-3-660 states, in part, that it is for the court to adjudge a deficiency. This statute, with its origins pre-dating the enactment of our Constitution, illustrates that a party does not have a right to a jury trial when he is included in the action solely for the purpose of obtaining a deficiency judgment. See also 27 S.C. Jur. Mortgages § 103 (stating mortgage foreclosure proceedings are regulated by statutes, and those statutes should be substantially followed). We therefore hold McKown is not entitled to a jury trial solely based on the Bank’s inclusion of him as a party pursuant to § 29-3-660.
Accordingly, we reverse the Court of Appeals’ holding that McKown was entitled to a jury trial solely based on the Bank’s inclusion of McKown as a party to obtain a possible deficiency judgment. That holding conflicts with § 29-3-660, which confers upon the court the power to adjudge a deficiency.
Having determined McKown is not entitled to a jury trial for the reason relied on by the Court of Appeals, we address whether McKown is entitled to a jury trial based on his counterclaims. We do so in the interest of judicial economy as this issue was not addressed squarely by the Court of Appeals.
II. McKown’s Right To A Jury Trial Based On His Civil Conspiracy And Breach of Contract Counterclaims.
The Bank argues the Court of Appeals erred because McKown’s counterclaims, while legal, are permissive and thus, *295McKown waived his right to a jury trial by asserting them in this equitable suit. We agree.
McKown is entitled to a jury trial on his counterclaims in an equitable action only if the counterclaims are legal and compulsory. See Rule 13(a), SCRCP. A counterclaim is compulsory if it arises out of the same transaction or occurrence as the party’s claim. Id. In a foreclosure action, a counterclaim arises out of the same transaction or occurrence and is thus compulsory, when there is a “logical relationship” between the counterclaim and the enforceability of the guaranty agreement. Cf. N.C. Fed. Sav. & Loan Ass’n, 298 S.C. at 518-19, 381 S.E.2d at 905-06 (finding a foreclosure defendant was entitled a jury trial because his counterclaims that the bank breached subsequent oral contracts to arrange additional financing were compulsory because they bore a logical relationship to the enforceability of the note).
Given this framework, we determine whether McKown’s legal counterclaims are compulsory.
a. Civil Conspiracy
McKown’s civil conspiracy counterclaim is based on an alleged conspiracy between the Bank and Rempher. McKown contended that two years after the execution of the notes and guarantees, Rempher was substituted in Christensen’s place as a member of BADD and began collecting rents from the income-producing warehouse units. Allegedly, Rempher had an ownership interest in other warehouse units not purchased by BADD and as a result, conspired with the Bank to induce BADD’s default by directing potential tenants away from renting the properties. McKown further claimed Rempher intentionally failed to make payments on the note even though sufficient funds were available because Rempher wanted to purchase the three warehouse units at a below market value, foreclosure sale.
Here, the execution of the guaranty agreements was the “transaction or occurrence” that gave rise to McKown’s inclusion in the Bank’s foreclosure complaint. McKown’s civil conspiracy counterclaim does not arise out of that transaction or occurrence because it bears no logical relationship to either the execution or enforceability of the guaranty agreements. *296Cf. N.C. Fed. Sav. & Loan Ass’n, 298 S.C. at 518-19, 381 S.E.2d at 905-06; Advance Int’l, Inc. v. N.C. Nat’l Bank of S.C., 316 S.C. 266, 270-71, 449 S.E.2d 580, 582-83 (Ct.App.1994), aff'd in part, vacated on other grounds, 320 S.C. 532, 466 S.E.2d 367 (1996) (finding claims of fraud, negligence, and unfair trade practices in a foreclosure action were not compulsory because those claims did not affect the enforceability of the note). In other words, the civil conspiracy claim presumes the enforceability of the guaranty agreements because the allegations, if true, would not render the guarantees unenforceable. We therefore hold McKown waived his right to a jury trial by asserting the civil conspiracy counterclaim in a foreclosure action because the claim is permissive as it does not arise out of the same transaction or occurrence as the execution of the guaranty agreements. See Johnson v. S.C. Nat’l Bank, 292 S.C. 51, 55, 354 S.E.2d 895, 897 (1987) (stating a defendant waives his right to a jury trial by asserting a permissive counterclaim in an equitable action).
b. Breach of Contract
The breach of contract claim is based on an allegation that Rempher agreed to obtain financing for the three units BADD mortgaged. The only allegation specific to the Bank is that the Bank breached its covenant of good faith and fair dealing implied in the note, mortgage, and guaranty agreements based on the Bank’s purported conspiracy with Rem-pher. Again, the “transaction or occurrence” for the purpose of determining the compulsory character of McKown’s counterclaim is the execution of the guaranty agreements. McKown’s “breach of covenant of good faith and fair dealing” claim depends on a purported conspiracy that took place, if at all, two years after the guarantees had been executed. This claim does not arise out of the underlying transaction or occurrence because it does not affect the execution or enforceability of the guaranty agreements. We therefore hold McKown waived his right to a jury trial by asserting a permissive counterclaim in the foreclosure action. Cf. Advance Int’l, Inc., 316 S.C. at 270-71, 449 S.E.2d at 582-83.
Conclusion
We reverse the Court of Appeals as McKown is not entitled to a jury trial solely because the Bank exercised its statutory *297right to join him as a party in the event of a deficiency judgment. We further hold McKown is not entitled to a jury trial based on his counterclaims, which, while legal, are permissive. McKown waived his right to a jury trial by asserting permissive counterclaims in an equitable action. Accordingly, the effect of our decision affirms the circuit court’s decision, which referred this matter in its entirety to the master-inequity.
The Court of Appeals decision is therefore
REVERSED.
TOAL, C.J., BEATTY, KITTREDGE and HEARN, JJ., concur.