
203 S.E.2d 117 (1974)
214 Va. 587
COUNTY OF CHESTERFIELD
v.
TOWN & COUNTRY APARTMENTS & TOWNHOUSES, etc., et al.
Supreme Court of Virginia.
March 4, 1974.
*118 Frederick T. Gray; Richmond, Morris E. Mason, Asst. Commonwealth's Atty. for Chesterfield County (Oliver D. Rudy, Commonwealth's Atty. for Chesterfield County, Williams, Mullen & Christian, Richmond, on brief), for appellant.
A. J. FitzPatrick, Asst. City Atty. for City of Richmond, Harry L. Thompson, Richmond (William S. Smithers, Jr., Minor, Thompson, Savage, Smithers & Benedetti, Richmond, on brief), for appellees.
Before SNEAD, C. J., and I'ANSON, CARRICO, HARRISON, COCHRAN, HARMAN and POFF, JJ.
CARRICO, Justice.
Code § 15.1-554 provides as follows:
"No action shall be maintained by any person against a county upon any claim or demand until such person shall have first presented his claim to the board of supervisors of such county for allowance."
The determinative question in this case is whether failure to comply with the foregoing Code section bars the maintenance against a county of a declaratory judgment proceeding which basically involves, so far as the county is concerned, a contractual dispute and a resulting monetary claim against the county. We answer the question in the affirmative.
The present declaratory judgment proceeding was brought against the County of Chesterfield and the City of Richmond by a partnership, Town & Country Apartments & Townhouses, whose land had recently been annexed to the City from the County. The motion for declaratory judgment sought a declaration that a pre-annexation "Sewer Agreement for Developer Participation" between the County and Town & Country had been fully executed and therefore was not applicable to 37 dwelling units for which Town & Country desired a sewer connection. The motion also sought a refund from the County of the sum of $11,100 Town & Country had paid, under protest, for connection of the 37 units at the County's rate of $300 per dwelling unit. Finally, the motion sought a declaration that the City should furnish Town & Country a sewer connection for the 37 units at the rate fixed by the City $229 for the single connection.
The County demurred to the motion for declaratory judgment, relying, among other grounds, upon failure of the motion to allege compliance with Code § 15.1-554, quoted above. The demurrer was overruled. Later, the trial court ruled that the "Sewer Agreement for Developer Participation" between the County and Town & Country had been fully executed and was not executory. Thereafter, the court granted the relief, including a monetary judgment against the County in the sum of $11,100, sought by Town & Country. The County has appealed; the City has not.
The allegations of the motion for declaratory judgment and certain exhibits before the trial court at the hearing on the demurrer disclose the factual situation pertinent to the question to be decided. Town & Country owned a tract of land which, prior to the effective date of the annexation decree, midnight of December 31, 1969, was located in the County. Town & Country, at the time the present proceeding was instituted, had completed construction on the tract of a number of apartment and townhouse units under Phase I of its project and was in the process of constructing other units under Phase II. On April 10, 1969, prior to annexation, the County and Town & Country had entered into a "Sewer Agreement for Developer Participation." *119 Thereafter, the County constructed a sewer line, the "Pocosham Creek Main Trunk," to which the units in Phase I of Town & Country's project were connected. The cost of connection, $60,000, had been prepaid by Town & Country under the terms of its agreement with the County and that sum was used to defray part of the expense of constructing the sewer line.
After the annexation decree became effective, Town & Country's property, as well as the "Pocosham Creek Main Trunk" sewer line, were located within the City. However, the County retained ownership of the line.
Following annexation, Town & Country undertook Phase II of its construction project. It was directed by the City to apply to the County for connection to the "Pocosham Creek Main Trunk" sewer line. Town & Country applied to the County to connect 37 units and paid, under protest, to the County the sum of $11,100, or $300 per dwelling unit. Later, Town & Country sought to withdraw its application to the County for the sewer connection and requested a refund of the $11,100 payment. No refund was made.
Town & Country thereafter applied to the City for the sewer connection. The City notified the County that it intended to grant the application at the City's rate of $229 in total for the connection. The County replied that under the terms of its "Sewer Agreement for Developer Participation" with Town & Country, the County was entitled to its per-dwelling-unit fee of $300, or $11,100 for the 37 units. The City then refused to grant Town & Country's application.
We are of opinion that the foregoing factual recitation demonstrates conclusively that the very foundation of Town & Country's dispute with the County is the claim for refund of the $11,100 paid, albeit under protest, pursuant to the "Sewer Agreement for Developer Participation." Town & Country contends that it is entitled to the refund and is not required to deal further with the County because the agreement is no longer operative. The County contends that it is entitled to retain the payment and to prescribe the charges for Town & Country's sewer connections because the agreement is still operative. This is precisely the type of "claim or demand" which is contemplated by Code § 15.1-554, previously quoted. Town & Country makes no pretext that it complied with the Code section by first presenting the claim to the Board of Supervisors of the County for allowance or that it alleged such compliance in its motion for declaratory judgment. Its failure in either respect bars maintenance of the present proceeding.
But, argues Town & Country, the present proceeding is equitable in nature and because Code § 15.1-554 "relates to `actions,'" the statute "would appear to exclude equity jurisdiction from its purview." We reject this argument. Aside from the fact that Town & Country's claim is basically legal in nature, we have previously ruled that the language, "claim or demand," contained in the statute in question, "is sufficiently broad to embrace every character of claim, whether legal or equitable." Nelson County v. Coleman, 126 Va. 275, 280, 101 S.E. 413, 414-415 (1919); accord, Fidelity & Deposit Company v. Gill, 116 Va. 86, 92-93, 81 S.E. 39, 42 (1914).
Town & Country argues further that Code § 15.1-554 cannot be "successfully interposed to defeat a Motion for Declaratory Judgment." We take this argument to have two prongs: first, that a motion for declaratory judgment is not subject to demurrer if it alleges the existence of an actual controversy; second, that failure to allege compliance with Code § 15.1-554 is not a proper subject of demurrer.
The answer to the first prong of Town & Country's argument is supplied by First National Trust & Savings Bank v. Raphael, 201 Va. 718, 721, 113 S.E.2d 683, 686 (1960). That case did not involve the Code section with which we are here concerned, but it established the rule that although *120 a motion for declaratory judgment may allege the existence of an actual or justiciable controversy, it should be dismissed upon demurrer if it fails to show a right to executory or declaratory relief. That same rule applies here.
The answer to the second prong of Town & Country's argument is found in Fidelity & Deposit Company v. Gill, supra. That case involved a bill of complaint in equity and not, as Town & Country describes the present proceeding, a motion for declaratory judgment seeking equitable relief. But the case nonetheless stands for the specific proposition that where a claim, whether legal or equitable in nature, is asserted against a county, failure to allege compliance with Code § 15.1-554 requires dismissal upon demurrer.
The rationale of the rule requiring compliance with Code § 15.1-554 is stated in Botetourt County v. Burger, 86 Va. 530, 533, 10 S.E. 264, 265 (1889). There, speaking of the antecedents of Code § 15.1-554 and its related statutes, Code §§ 15.1-550 to 15.1-553 (which need not be set out in full), we said:
"This is the mode prescribed by law, by which claims may be collected against the county, and the county cannot be sued in any other mode than that provided by law. The county is a political sub-division of the state, and can only be sued when and in the manner prescribed by law. The sovereign can be sued only by its own consent, and a state granting the right to its citizens to bring suit against it can be sued only in the mode prescribed. The same principles apply to a county, which is a part of the state, which is, as we have said, a political sub-division of the state, suable only in the mode prescribed in the law granting the right to sue.
"He who avails of the grant must follow its terms."
The case of Johnson v. Black, 103 Va. 477, 49 S.E. 633 (1905), relied upon by Town & Country, is not applicable to the present situation. There, taxpayers, by a suit in equity against a board of supervisors and the members thereof, sought to compel the restoration to the county treasury of public funds illegally paid to the respective members of the board. We held that such a type of suit, because of its nature, was, and traditionally had been, the proper subject of equitable inquiry in the absence of compliance with the antecedents of Code § 15.1-554 and its related statutes. A situation quite different is presented here.
For the failure of Town & Country to allege compliance with Code § 15.1-554, the County's demurrer should have been sustained. For the failure of the trial court to sustain the demurrer, the final order, so far as it affects the County, will be reversed and Town & Country's motion for declaratory judgment, so far as it relates to the County, will be dismissed.
Reversed and dismissed.
