The Taxation and Revenue Department (department) appeals from a judgment declaring all properties owned by Masonic lodges exempt from property taxes under the New Mexico Constitution, article VIII, Section 3. The department contends that the trial court applied an erroneous standard of law in concluding that the properties are tax-exempt, and that under the correct standard, the Masonic lodges are not used for educational or charitable purposes. See id. We reverse and remand with instructions to dismiss the petition for lack of jurisdiction.
The record indicates that properties owned by Masonic lodges in New Mexico have not been assessed for a number of *180years, on the ground that the properties are used for charitable or educational purposes. Beginning with the 1983 tax year, the legislature required that non-governmental entities claim the exemptions by filing proof of eligibility with the county assessor; however, once allowed, the exemptions need not be claimed again until there is a change in eligibility. See NMSA 1978, § 7-38-17(C), (F) (Repl.1986). If claims for exemptions were not filed by the last day of February 1983, the property was presumed not to be exempt and was taxed.
In response to a request for a ruling concerning property owned by Sacramento Lodge No. 24, located in Alamogordo, the department concluded that this property is not used for educational or charitable purposes within the meaning of article VIII, Section 3. The ruling, P.T.D. Ruling No. 83-02, also stated that each request for property tax exemption must be evaluated on its own facts and that other cases, while illustrative, are not controlling. The ruling therefore held that Temple Lodge No. 6, A.F. & A.M. v. Tierney, 37 N.M. 178, 20 P.2d 280 (1933) is not dispositive of the facts presented by the Sacramento Lodge.
Subsequently, four groups of Masons, representing all of the Masonic lodges in New Mexico, filed a petition for declaratory judgment in district court. The petition states that, since the ruling, many county assessors have issued notices to lodges that their properties are no longer exempt, and it is anticipated that such assessments will soon be made on a statewide basis. The petition asked the district court to issue a declaratory judgment that all Masonic lodges affiliated with any of the petitioners are exempt from property taxes, contrary to the ruling. The court issued an order staying any further notices of assessment on Masonic properties, and any administrative proceedings involving notices and protests filed pursuant thereto, until a final determination was made with respect to the taxability of the properties. After trial, the court entered findings and conclusions which did not differentiate among the associated lodges and an order granting petitioners tax-exempt status, on the ground that their operations are both educational and charitable in nature. The department appeals this order.
The record does not reflect that exemptions have been denied to any lodge other than Sacramento Lodge No. 24. In fact, P.T.D. Ruling No. 83-03 states that “[e]ach request for property tax exemption under Article VIII, § 3 of the New Mexico Constitution must be evaluated on its own facts, and other cases, although illustrative, are not controlling.” Fifty-seven other lodges were involved in the litigation in district court. Based on the allegations in the petition, they had not all been assessed.
After this case was submitted to this panel for decision, the court requested supplemental briefing on the jurisdiction of the district court to enter the order from which the department appeals. See State ex rel. Overton v. New Mexico State Tax Comm’n, 81 N.M. 28, 462 P.2d 613 (1969). We asked the parties to discuss the jurisdiction of the district court with respect to the lodges other than Sacramento Lodge No. 24, it appearing that there is at present no actual controversy as to them; and as to Sacramento Lodge No. 24, whether the trial court lacked jurisdiction because this lodge had not exhausted its administrative remedies. For the following reasons, we now reverse.
The petition was filed pursuant to the Declaratory Judgment Act. See NMSA 1978, Sections 44-6-1 to -15. Under the act, district courts can declare rights, status, and other legal relations “[i]n cases of actual controversy.” § 44-6-2. There must be an actual controversy before a court has jurisdiction to hear a declaratory judgment action. State ex rel. Overton v. New Mexico State Tax Comm’n. The supreme court has held that the elements of actual controversy for this purpose are:
[(1)] a controversy involving rights or other legal relations of the parties seeking declaratory relief; [(2)] a claim of right or other legal interest asserted against one who has an interest in contesting the claim; [ (3) ] interests of the *181parties must be real and adverse; and [ (4) ] the issue involved must be ripe for judicial determination.
In addition to the statutory requirement of actual controversy, case law holds that the district court does not have jurisdiction over a declaratory judgment action unless the parties have first exhausted any administrative remedies. See State Racing Comm’n v. McManus, 82 N.M. 108, 476 P.2d 767 (1970). This is analogous to the procedural rule which precludes appellate review prior to a final judgment of the trial court. Cf. Illinois Bell Tel. Co. v. Allphin, 60 Ill.2d 350, 326 N.E.2d 737 (1975) (holding that as no hearing had yet been held and no formal final assessment had issued, the revenue department had not reached a final administrative decision; thus, under the state administrative act, the agency’s notice of tax liability will not be reviewable).
Actions for declaratory judgment were not intended as a substitute for statutory judicial review of administrative action. Hays v. City & County of Denver, 127 Colo. 154, 254 P.2d 860 (1953); V-1 Oil Co. v. County of Bannock, 97 Idaho 807, 554 P.2d 1304 (1976). They should not be used to usurp or replace specific administrative relief. City of Cheyenne v. Sims, 521 P.2d 1347 (Wyo.1974). The theory which underlies administrative law is that the issues with which it deals ought to be decided by experts. Weyerhaeuser Timber Co. v. Galloway, 168 Or. 85, 121 P.2d 469 (1942).
The supreme court has held that before resort to a court of equity can be had for relief from discriminatory taxation, the complaining taxpayer must have either no adequate legal or statutory remedy, or he must have first exhausted the same without avail. First National Bank of Raton v. McBride, 20 N.M. 381, 149 P. 353 (1915). This doctrine was extended to declaratory judgments in Associated Petroleum Transp., Ltd. v. Shepard, 53 N.M. 52, 201 P.2d 772 (1949).
Consequently, the declaratory judgment statute must be read in tandem with statutes providing judicial review of administrative actions. Chesapeake and Potomac Co. v. State Tax Dep’t, 161 W.Va. 77, 239 S.E.2d 918 (1977). Whether statutory relief is exclusive depends on legislative intent. See E. Borchard, Declaratory Judgments 344 (2d ed.1941). Where there is a complete remedy otherwise provided by statute, and obviously intended to be exclusive, the issue is not subject to disposition by declaratory judgment. Crews v. Collins, 252 Iowa 863, 109 N.W.2d 235 (1961). See generally 2 F. Cooper, State Administrative Law 605-611 (1965) (discussing the rule that where a statutory method of review is provided, that method is exclusive); Annot., Tax Questions as Proper Subject of Action for Declaratory Judgment, 11 A.L.R.2d 359 (1950).
We doubt that an actual controversy exists as to those lodges other than Sacramento Lodge No. 24. Any injury to those lodges is speculative, based on the assumption that they will be assessed, and they are seeking in effect an advisory opinion. Cf. Sanchez v. City of Santa Fe (where defendants required plaintiffs to pay fee and plaintiffs refused to do so, an actual controversy existed). However, we are persuaded that the dispositive issue is whether there is an adequate remedy other than declaratory judgment, which all petitioners have failed to pursue. We conclude that there is.
The power to grant or deny exemptions lies with the county assessors and the Property Tax Division. See NMSA 1978, §§ 7-38-22, -24 (Repl.1986). The denial of an exemption by the county assessor may be reviewed by a county valuation protests board. NMSA 1978, § 7-38-27 (Repl.1986). Orders resulting from these reviews may be appealed to this court. NMSA 1978, § 7-38-28 (Repl.1986). A property owner also may protest by filing a claim for refund after paying the taxes alleged to be due. See NMSA 1978, § 7-38-21 (Repl. 1986).
The department contends that there is no provision for protesting the denial of an exemption by ruling. See NMSA 1978, § 7-l-5(B)(2) (Repl.1986). The record sup*182ports a conclusion that petitioners in effect were attempting to protest the ruling by bringing a petition for declaratory judgment. The complaint expressly states, however, that the ruling “constitutes a substantial departure from prior authority and the long standing past practice followed ... statewide ... pursuant to judicial precedent____” For this reason, the complaint also in effect asks the district court to construe the ruling as beyond the department’s authority. See Utah Fuel Co. v. National Bituminous Coal Comm’n, 306 U.S. 56, 59 S.Ct. 409, 83 L.Ed. 483 (1939). A party will not be required to exhaust the administrative procedures if there is no adequate administrative remedy. See State ex rel. Maloney v. Sierra, 82 N.M. 125, 477 P.2d 301 (1970).
Assuming that there is no method for reviewing a ruling, that is not dispositive. A ruling, by its statutory definition, is in the nature of an interlocutory decree or advisory opinion. See § 7-l-5(B)(2). The legislature has provided a comprehensive scheme for protesting department and county actions. In not providing more specifically for judicial review of a ruling, we understand the legislative intent to be that the ruling should be applied before it is reviewed, in the absence of some applicable exception. See § 7-l-5(G). Compare Verkouteren v. Supervisor of Assessments, 38 Md.App. 216, 380 A.2d 642 (1977) (relying on the state statutory provision governing declaratory judgments) with Peterson Properties, Del Rio Plaza Shopping Center v. Valencia County Valuation Protests Bd., 89 N.M. 239, 549 P.2d 1074 (Ct.App.1976) (administrative board’s oral statement of the reasons it was going to make a certain decision was not an appeal-able final order).
Petitioners concede that the Property Tax Code, see NMSA 1978, Section 7-35-1 (Repl.1986), makes tax-exempt status available on an individual basis. See Temple Lodge No. 6 v. Tierney. An exemption dependent on the use of property is solely a question of fact. City of Cheyenne v. Sims. Our cases have been consistent in this respect. See Benevolent and Protective Order of Elks, Lodge No. 461 v. New Mexico Property Appraisal Dep't, 83 N.M. 445, 493 P.2d 411 (1972) (determination whether property is used for charitable purposes must necessarily depend on the uses being made of each property which is claimed to come within the exemption; except to the extent that the facts as to use are so nearly alike as to logically compel like results, no case can be said to constitute a controlling precedent for another case in this area); Santa Fe Lodge No. 460, B.P.O.E. v. Employment Sec. Comm’n, 49 N.M. 149, 159 P.2d 312 (1945) (confining decision to facts); Albuquerque Lodge, No. 461, B.P.O.E. v. Tierney, 39 N.M. 135, 42 P.2d 206 (1935) (decision not making a precedent even for other cases involving properties of the B.P.O.E. except as the proven facts disclose a similar use); Albuquerque Alumnae Ass’n of Kappa Kappa Gamma Fraternity v. Tierney, 37 N.M. 156, 20 P.2d 267 (1933). They argue, however, that the statutory remedy is inadequate when the resolution as to every lodge turns on a single common legal question, rather than one of fact. See Pan American Petroleum Corp. v. El Paso Natural Gas Co., 77 N.M. 481, 424 P.2d 397 (1966).
To be exempt from property taxes, property need not be used exclusively for charitable or educational purposes, but those must be the primary or substantial uses. Temple Lodge No. 6 v. Tierney; NRA Special Contribution Fund v. Board of County Comm’rs, 92 N.M. 541, 591 P.2d 672 (Ct.App.1978); Rutherford v. County Assessor for Bernalillo County, 89 N.M. 348, 552 P.2d 479 (Ct.App.1976). This court has noted, further, that the “direct and immediate use” of the property is the relevant issue. NRA Special Contribution Fund v. Board of County Comm’rs. In addition, it is the actual use of the property, not the owner’s declared objects and purposes, that determines the right to an exemption. See Santa Fe Lodge No. 460 v. Employment Sec. Comm’n; Albuquerque Lodge, No. 461 v. Tierney.
The exemption granted educational and charitable institutions proceeds upon the theory of the public good accomplished by *183them and the peculiar benefits derived by the public in general from their conduct. State v. Locke, 29 N.M. 148, 219 P. 790 (1923). Property which is exempt from taxation does not share in the burden of the cost of government; thus, in exchange for its exempt status, such property must confer a substitute substantial benefit on the public. NRA Special Contribution Fund v. Board of County Comm’rs.
Thus, under these cases, there must be evidence concerning the primary and substantial use of the property. See United Veterans Org. v. New Mexico Property Appraisal Dep’t, 84 N.M. 114, 500 P.2d 199 (Ct.App.1972). The purposes must be within the standards developed by case law. For example, “used for educational purposes” means the direct, primary, and substantial use of property that embraces systematic instruction in any and all branches of learning from which a substantial public benefit is derived. NRA Special Contribution Fund v. Board of County Comm’rs (quoting McKee v. Evans, 490 P.2d 1226, 1230 (Alaska 1971)). “Substantial public benefit” is “benefit of real worth and importance to any indefinite class of persons who are a part of the public, which benefit comes to these persons from the use of property.” Id., 92 N.M. at 549, 591 P.2d at 680. Any purpose is “charitable” which is one of the types stated in the preamble to the English Statute of Charitable Uses, such as relief of the aged or maintenance of the sick. Santa Fe Lodge No. 460 v. Employment Sec. Comm’n.
The record on appeal supports a conclusion that each lodge operates differently. Their income, expenditures, and percentage of income given to charitable purposes are all different. While records from the various lodges were admitted into evidence, there were no findings concerning any individual lodge or any percentage of income used for charity. Under the relevant standard, separate decisions for each lodge are required. See Temple Lodge No. 6 v. Tierney.
The constitution has provided a charitable exemption for which our cases recognize the propriety of a case-by-case analysis. The statutory scheme provided by the legislature permits an orderly, expert, and consistent resolution of requests for an exemption on a case-by-case basis. The appellate review provided by the legislature ordinarily follows the completion of the process by assessment and allows the appellate court to review an administrative record. See § 7-38-28(A), (B), & (D).
Under these circumstances, we conclude that the legislature, in enacting a comprehensive scheme for administrative and judicial review, has provided the exclusive remedy for the claims presented to the district court, and that the administrative remedies provided by the legislature must be exhausted. See generally Annot., Justiciable Controversy Within Declaratory Judgment Act as Predicable Upon Advice, Opinion, or Ruling of Public Administrative Officer, 149 A.L.R. 349 (1944). To permit judicial review of the ruling by declaratory judgment would eliminate the administrative record or substitute and avoid the standard of review the legislature has provided.
Jurisdiction does not lie in the court until the statutorily required administrative procedures are complete. See Application of Angel Fire Corp., 96 N.M. 651, 634 P.2d 202 (1981). The Declaratory Judgment Act does not enlarge the jurisdiction of the district court. Allstate Ins. Co. v. Firemen’s Ins. Co., 76 N.M. 430, 415 P.2d 553 (1966). The ruling was within the express statutory power of the department. It is consistent with the relevant provision of the state constitution and the cases interpreting that provision. There being no relevant exception, see National Account Sys., Inc. v. Anderson, 82 Ill.App.3d. 233, 37 Ill.Dec. 654, 402 N.E.2d 656 (1980), we hold that the trial court lacked jurisdiction to decide the tax-exempt status of any of the lodges.
On these facts, we conclude that an action for declaratory judgment prior to assessment and protest would bypass significant parts of the administrative process and otherwise circumvent the legislature’s intent. We therefore remand to the dis*184trict court with instructions to dismiss the petition for lack of jurisdiction. No costs are awarded.
IT IS SO ORDERED.
ALARID and APODACA, JJ., concur.