
43 Cal.2d 815 (1955)
TIDE WATER ASSOCIATED OIL COMPANY (a Corporation), Petitioner,
v.
SUPERIOR COURT OF LOS ANGELES COUNTY, Respondent; PORTER SESNON et al., Real Parties in Interest.
L. A. No. 23262. 
Supreme Court of California. In Bank.  
Jan. 25, 1955.
 Herbert W. Clark, William F. Kiessig, Robert D. Raven, Scott L. Harrington, Morrison, Hohfeld, Foerster, Shuman & Clark, Oscar C. Sattinger, Twitchell & Rice, Overton, Lyman, Prince & Vermille and Donald H. Ford for Petitioners.
 Edmund G. Brown, Attorney General, and John F. Hassler, Deputy Attorney General, as Amici Curiae on behalf of Petitioners.
 Harold W. Kennedy, County Counsel (Los Angeles), and John B. Anson, Deputy County Counsel, for Respondent.
 Everett S. Layman, Kenneth S. Carey, Lawrence W. Jordan, Jr., James M. Dennis and Everett S. Layman, Jr., for Real Parties in Interest.
 GIBSON, C.J.
 Each of these three cases arises out of a suit brought by the state to enjoin unreasonable waste of gas, and each involves the question whether certain defendants are entitled to a writ of prohibition to prevent the trial of issues raised by a cross-complaint filed by other defendants.
 Following a complaint by some of the operators in an oil field that there was an unreasonable waste of gas contrary to the provisions of section 3300 of the Public Resources Code.  [fn. 1] the State Oil and Gas Supervisor held hearings pursuant *820 to section 3302 et seq., determined that gas was being wastefully produced and ordered all operators in the field to cease production of gas in excess of a specified rate. Appeal was taken to the board of oil and gas commissioners for the district, and the findings and order of the supervisor were adopted with slight modifications. A suit was then brought by the People pursuant to sections 3310  [fn. 2] and 3312  [fn. 3] of the Public Resources Code to enjoin unreasonable waste of gas. Certain defendants filed a cross-complaint seeking to enjoin the other defendants from wasting gas and to recover damages from all but one of them for past waste. Demurrers to the cross-complaint were overruled, and motions to strike it were denied. Petitioners then sought prohibition, claiming that respondent court has no power to consider a cross-complaint in this type of suit. [1] The availability of the writ depends upon whether petitioners have any other plain, speedy and adequate remedy, and whether respondent court, in trying the issues raised by the cross-complaint, would be acting without or in excess of its jurisdiction.
 [2] When the trial court overruled the demurrers and denied the motions to strike, it in effect ordered the case to trial upon the cross- complaint as well as upon the complaint. These rulings are not immediately reviewable by appeal, since they are not final judgments and do not otherwise come within the appealable orders enumerated in section 963 of the Code of Civil Procedure. [3] Although the propriety of the court's action may, of course, be reviewed upon appeal from a final judgment in the case, this would not constitute a plain, speedy or adequate remedy because petitioners would be required to undergo the delay and expense of a complicated, lengthy trial upon the question of damages. (Tomales Bay *821 etc. Corp. v. Superior Court, 35 Cal.2d 389, 392 [217 P.2d 968]; Providence Baptist Church v. Superior Court, 40 Cal.2d 55, 60 [251 P.2d 10].) [4] The matter of damages is not presented by the complaint but only by the cross-complaint and, unlike the injunction issues, may be subject to jury trial. Under these circumstances prohibition would appear to be the only adequate remedy available to petitioners to test the jurisdiction of the court to try the issues raised by the cross-complaint.
 [5] The term jurisdiction has a broader meaning when used in considering the availability of prohibition to review an order than when used in determining whether a court lacks power in the fundamental sense, i. e., whether it has jurisdiction over the subject matter and the parties. (Abelleira v. District Court of Appeal, 17 Cal.2d 280, 287-291 [109 P.2d 942, 132 A.L.R. 715]; see also Rescue Army v. Municipal Court, 28 Cal.2d 460, 463-464 [171 P.2d 8].) [6] Any acts which exceed the power of a court, whether defined by statute or by rules developed and followed under the doctrine of stare decisis, may be restrained by prohibition. (Abelleira v. District Court of Appeal, 17 Cal.2d 280, 287-291 [109 P.2d 942, 132 A.L.R. 715].) We must, therefore, examine the applicable statutes and case law to determine whether a cross-complaint may be used by one defendant against another in a suit brought by the People, pursuant to the provisions of the Public Resources Code, to enjoin the unreasonable waste of gas.
 Section 442 of the Code of Civil Procedure provides, "Whenever the defendant seeks affirmative relief against any party, relating to or depending upon the contract, transaction, matter, happening or accident upon which the action is brought, or affecting the property to which the action relates, he may, in addition to his answer, file ... a cross-complaint. ..." (Italics added.) An action is defined as "an ordinary proceeding in a court of justice by which one party prosecutes another for the declaration, enforcement, or protection of a right, the redress or prevention of a wrong, or the punishment of a public offense." (Code Civ. Proc.,  22.) "Every other remedy is a special proceeding." (Code Civ. Proc.,  23.) [7] Section 442 is a general provision which, in the absence of a specific statute to the contrary, is sufficiently broad to permit the use of a cross-complaint in any "action." It does not, however, on its face authorize the use of a cross- complaint in a "special proceeding." *822
 The first question to be determined is whether this suit falls within the classification of an "action" or whether it is a "special proceeding."  [fn. 4] [8] As a general rule, a special proceeding is confined to the type of case which was not, under the common law or equity practice, either an action at law or a suit in equity. (In re Sutter-Butte By-Pass Assessment, 190 Cal. 532, 537 [213 P. 974]; In re Central Irr. Dist., 117 Cal. 382, 387 [49 P. 354].) [9] The suit authorized by statute in the present case is one "to enjoin" the unreasonable waste of gas, and an injunction, of course, is a well known equitable remedy. (See Pomeroy, Equity Jurisprudence [5th ed., 1941],  110, 112, pp. 141-142, 145.) In County of Yuba v. North American etc. Min. Co., 12 Cal.App. 223, 225 [107 P. 139], it was held that a suit by a county to enjoin defendants from depositing mining debris in a river to the injury of plaintiff's property was an action and not a special proceeding within the meaning of sections 22 and 23 of the Code of Civil Procedure. In Van Bibber v. Hilton, 84 Cal. 585, 587 et seq. [24 P. 308, 598], the plaintiff sought to enjoin the diversion of the waters of a stream, and the court referred to the suit as an action and held that the asserted claims of defendants to water rights were properly set forth by way of cross-complaint under section 442 of the Code of Civil Procedure. [10] The legislation authorizing the People to obtain an injunction against the unreasonable waste of gas is designed not only to protect the interests of the public but also to preserve the rights of owners and operators. (See Bandini Petroleum Co. v. Superior Court, 284 U.S. 8, 21-22 [52 S.Ct. 103, 108, 76 L.Ed. 136. 78 A.L.R. 826]; Bandini Petroleum Co. v. Superior Court, 110 Cal.App. 123, 134-138 [293 P. 899]; People v. Associated Oil Co., 212 Cal. 76, 80-81 [297 P. 536]; Bernstein v. Bush, 29 Cal.2d 773, 780 [177 P.2d 913].) It is provided that, with certain exceptions not relevant here, the practice is to be governed by the provisions of the Code of Civil Procedure relating to injunctions. (Pub. Resources Code,  3310-3313; Code Civ. Proc.,  525-534.) [11] This suit is essentially the same as any other *823 action in equity in which the remedy of injunction may be used. It is a suit by which the People are prosecuting other parties for the enforcement or protection of a right and the prevention of a wrong. Accordingly, it is an "action" and not a "special proceeding."
 Carpenter v. Pacific Mut. Life Ins. Co., 10 Cal.2d 307 [74 P.2d 761], relied on by petitioners in support of their contention that the present suit is a special proceeding, is distinguishable. In that case the state Insurance Commissioner, acting pursuant to the provisions of the Insurance Code, petitioned the superior court for an order affirming a plan which he proposed for the rehabilitation of an insolvent insurance company. This court, in holding that a special proceeding and not an action was involved, pointed out that the commissioner was not prosecuting another party for the declaration, enforcement or protection of a right, the redress or prevention of a wrong, or the punishment of a public offense,--that it was not a proceeding in which one "party is prosecuting another party at all." (10 Cal.2d 307, 327.)
 [12a] Petitioners assert that section 442 relating to cross- complaints, although applicable generally to actions, may not be used in a suit to enjoin waste of gas because, they argue, the reference in sections 3311 and 3313 of the Public Resources Code to the injunction provisions of the Code of Civil Procedure, together with the failure to mention other sections of that code such as section 442, discloses a legislative intent to prohibit the use of the other sections. However, neither the Public Resources Code nor the injunction provisions to which it refers expressly prohibit use of a cross-complaint, and, by reason of the direct language of section 442 permitting a defendant to file a cross- complaint in an action, there is no room for the rule of statutory construction urged by petitioners. Moreover, the rules of practice set forth in the injunction provisions referred to do not purport to be complete in themselves but assume that other provisions of the Code of Civil Procedure shall apply insofar as they are consistent with the sections relating to injunctions. In accord with these views are a number of decisions which, without discussion of the problem, applied various sections of the Code of Civil Procedure to suits brought under the statutes involved here as they existed prior to codification in the Public Resources Code. (Superior Oil Co. v. Superior Court, 6 Cal.2d 113, 116-119 [56 P.2d 950] [holding that *824  583 required dismissal of state's action]; People v. Associated Oil Co., 212 Cal. 76, 78 [297 P. 536] [permitting the taking of additional evidence on appeal under  956a]; People v. Associated Oil Co., 211 Cal. 348, 349 [296 P. 273] [same]; Ambassador Petroleum Co. v. Superior Court, 208 Cal. 667, 671 [284 P. 445] [applying  389, which authorized the court to bring in additional parties].)
 The cases holding that cross-pleading is not permissible in unlawful detainer proceedings are clearly not in point. (See Cheney v. Trauzettel, 9 Cal.2d 158, 159-161 [69 P.2d 832]; Schubert v. Lowe, 193 Cal. 291, 294-295 [223 P. 550]; Arnold v. Krigbaum, 169 Cal. 143, 145-146 [146 P. 423, Ann.Cas. 1916D 370]; Rydell v. Beverly Hills P. & P. Co., 88 Cal.App. 216, 219 [262 P. 818]; Smith v. Whyers, 64 Cal.App. 193, 194-195 [221 P. 387]; Knight v. Black, 19 Cal.App. 518, 527-528 [126 P. 512]; see Brawner v. Wilson, 126 Cal.App.2d 381, 385 [271 P.2d 937]; Lakeside Park Assn. v. Keithly, 43 Cal.App.2d 418, 422 [110 P.2d 1055]; Bekins v. Trull, 69 Cal.App. 40, 45-46 [230 P. 24].) [13] The Legislature has specifically designated unlawful detainer as a special proceeding, and, accordingly, it does not fall within the terms of section 442, which, as we have seen, does not purport to apply to special proceedings. The unlawful detainer statutes, of course, could have made section 442 applicable, but instead they provide that a defendant may file an answer or demurrer, and this has been construed as limiting a defendant to those pleadings and as excluding the use of a cross-complaint.  [fn. 5] (Schubert v. Lowe, 193 Cal. 291, 294-295 [223 P. 550].) [14] Moreover, an unlawful detainer proceeding is summary in character, and some of the decisions have pointed out that the use of a cross-complaint in such a case would frustrate the remedy and render it inadequate. [15] The same factors are not present in a suit brought to enjoin the waste of gas pursuant to the provisions of the Public Resources Code. While the statute, in specifying brief periods within which different steps may be taken before the administrative officers, evidences a legislative intent that the administrative hearings should be handled expeditiously, there is nothing which indicates *825 that the judicial proceeding was intended to be summary in character or otherwise essentially different from an ordinary suit for injunctive relief. [16] The interests of the public may be protected immediately upon filing the suit through the issuance of a preliminary injunction, as was done in the present case; and the owners and operators in the field, by the use of a cross- complaint, may protect their interests and obtain a complete settlement of the entire controversy in one action, thus avoiding unnecessary piecemeal litigation.
 Although our determination that a cross-complaint is permissible is based upon the conclusion that the suit is an action within the meaning of section 442 of the Code of Civil Procedure, we should point out that even if the suit were held to be a special proceeding, as contended by petitioners, it would not follow that a trial of the issues raised by the cross-complaint would be in excess of the court's jurisdiction. [17] Courts have inherent power, as well as power under section 187 of the Code of Civil Procedure,  [fn. 6] to adopt any suitable method of practice, both in ordinary actions and special proceedings, if the procedure is not specified by statute or by rules adopted by the Judicial Council. It is not only proper but at times may be necessary for a court to follow provisions of the Code of Civil Procedure which are harmonious with the objects and purposes of the proceeding although those provisions are not specifically made applicable by the statute which creates the proceeding. As we have seen, there is no statute prohibiting use of a cross-complaint in a suit to enjoin waste of gas. [12b] Further, the rules of practice which are expressly made applicable to such a suit do not purport to be complete in themselves, and there is, therefore, no basis for an implication that those rules were intended to be exclusive. [18] In addition, there are no rules developed under the doctrine of stare decisis which would bar use of a cross-pleading in the present situation. [19] Accordingly, even if the suit were held to be a special proceeding, it would be within the power of the court to pass upon the *826 question whether application of section 442 would be in harmony with the purposes of the particular type of suit, and an erroneous determination would be within and not in excess of the court's jurisdiction, as that term is used in prohibition cases. (See Abelleira v. District Court of Appeal, 17 Cal.2d 280, 287-291 [109 P.2d 942, 132 A.L.R. 715].)
 [20] It is further contended that, regardless of whether a cross- complaint is permissible in a suit of this kind, prohibition will lie here because, it is asserted, cross-complainants failed to exhaust their administrative remedies in that they did not petition the Director of Natural Resources for a hearing on the issue of gas wastage pursuant to section 3302 of the Public Resources Code,  [fn. 7] which provides for a hearing upon complaint by any person operating in the field. (See Abelleira v. District Court of Appeal, 17 Cal.2d 280, 291-293 [109 P.2d 942, 132 A.L.R. 715] [jurisdictional effect of failure to exhaust administrative remedy].) Such a proceeding was commenced by other operators, and cross-complainants were parties to it and participated both in the hearing before the supervisor and in the subsequent appeal to the board of oil and gas commissioners for the district. Under these circumstances, the filing by cross-complainants of a petition for an administrative hearing would have been an idle act, which the law does not require. Moreover, it is obvious that cross-complainants had no administrative remedy with respect to damages.
 [21] Pacific Lighting Gas Supply Company advances a contention, applicable only to it, in support of its claim that the court lacks jurisdiction to try the issues raised by the cross-complaint. The statute making the unreasonable waste of gas unlawful refers specifically to waste by a lessor, lessee or operator. (Pub. Resources Code,  3300.) Pacific asserts that it is a purchaser of gas from other defendants, that it is not a lessor, lessee or operator and that for this reason the cross- complaint does not and cannot state a cause of action against it. The only allegation appearing in the cross-complaint *827 which purports to connect Pacific with any alleged wrongful act is that "cross-defendant Carlton Beal has an obligation to the Sesnon group not to produce waster wells" and "all of the cross-defendants other than Carlton Beal had notice of his obligation and that it arose from a trust." The cross-complaint, therefore, does not state a cause of action against Pacific.
 [22] It is the general rule that the failure to state facts sufficient to constitute a cause of action does not deprive a court of the power to hear and determine a controversy if it has jurisdiction of the parties and the subject matter. (Athearn v. Nicol, 187 Cal. 86, 93-94 [200 P. 942]; Sutter Butte Canal Co. v. Superior Court, 183 Cal. 321, 324-325 [191 P. 529]; Woodworth v. Superior Court, 153 Cal. 38 [94 P. 232]; Bishop v. Superior Court, 87 Cal. 226, 230-233 [25 P. 435]; Felton Water Co. v. Superior Court, 82 Cal.App. 382, 388 [256 P. 255]; Yolo Water etc. Co. v. Superior Court, 43 Cal.App. 332, 337 et seq. [185 P. 195]; cf. 1 Witkin, California Procedure [1954], 380 et seq.) Respondent court has jurisdiction of Pacific as a party, and it also has jurisdiction of the type of case involved; it, therefore, has jurisdiction in the fundamental sense. Pacific appears to take the position that, in view of the broader meaning given to the term jurisdiction when used in considering the availability of prohibition, a court should be restrained from proceeding against a defendant in an action arising from an act made wrongful by statute where the pleading fails to state a cause of action and the defect cannot be cured by amendment. (Cf. Redlands High Sch. Dist. v. Superior Court, 20 Cal.2d 348, 360 [125 P.2d 490].) We are not faced with this question, however, since it does not appear that the cross-pleading cannot be amended to state a cause of action. [23] Even though a person is not a lessor, lessee or operator in the field, he may under some circumstances be liable for the waste of gas. [24] It is settled that where there is a common plan or design to commit a tort, all who participate are jointly liable whether or not they do the wrongful acts. (Mary Pickford Co. v. Bayly Bros., Inc., 12 Cal.2d 501, 515 [86 P.2d 102]; Revert v. Hesse, 184 Cal. 295, 301, 303 [193 P. 943]; see also Rest., Torts,  876; Prosser on Torts [1941], pp. 1094-1096.) Pacific, therefore, could be liable to cross-complainants if it was a joint tort feasor, even though it was not a lessor, lessee or operator, and cross- complainants claim *828 that they can amend their pleading to state a cause of action on this theory.
 The alternative writ is discharged, and the peremptory writ is denied.
 Shenk, J., Edmonds, J., Carter, J., Traynor, J., Schauer, J., and Spence, J., concurred.
NOTES
[fn. 1]  1. Section 3300 of the Public Resources Code provides as follows: "The unreasonable waste of natural gas by the act, omission, sufferance, or instance of the lessor, lessee or operator of any land containing oil or gas, or both, whether before or after the removal of gasoline from the gas, is opposed to the public interest and is unlawful. The blowing, release, or escape of gas into the air shall be prima facie evidence of unreasonable waste."
[fn. 2]  2. Section 3310 of the Public Resources Code provides in part as follows: "When the decision of the supervisor that there is an unreasonable waste of gas occurring or threatened, has become final, a certified copy thereof, or, if modified by the order of the board of district commissioners, then a certified copy of the order as modified, shall be filed with the director. The director, unless the order is complied with voluntarily, shall have proceedings instituted in the name of the people of the State of California to enjoin the unreasonable waste of gas."
[fn. 3]  3. Section 3312 of the Public Resources Code provides in part as follows: "Whenever it appears to the director that the owners, lessors, lessees, or operators of any well or wells producing oil and gas or oil or gas are causing or permitting an unreasonable waste of gas, he may institute, or have proceedings instituted, in the name of the people of the State of California, to enjoin the unreasonable waste of gas regardless of whether proceedings have or have not been instituted under sections 3302 to 3305, and regardless of whether an order has or has not been made therein."
[fn. 4]  4. There is no claim that the cross-complaint fails to comply with the requirement of section 442 that the relief sought relate to the same "contract, transaction, matter, happening or accident" or affect the "property" referred to in the complaint. An erroneous determination in this respect, as distinguished from a ruling requiring a party to proceed to trial on a cross-complaint where no such pleading is permitted, would not relate to the jurisdiction of the court. (Lichtenstein v. Superior Court, 85 Cal.App.2d 486 [193 P.2d 508].)
[fn. 5]  5. In eminent domain, which has likewise been classified as a special proceeding, it has been held that a cross-complaint is proper. (People v. Buellton Dev. Co., 58 Cal.App.2d 178, 185 et seq. [136 P.2d 793].) This holding, however, is not inconsistent with the unlawful detainer cases because, as pointed out in the Buellton case, the eminent domain statutes authorize the use of a cross-complaint.
[fn. 6]  6. Section 187 of the Code of Civil Procedure provides: "When jurisdiction is, by the constitution or this code, or by any other statute, conferred on a court or judicial officer, all the means necessary to carry it into effect are also given; and in the exercise of this jurisdiction, if the course of proceeding be not specifically pointed out by this code or the statute, any suitable process or mode of proceeding may be adopted which may appear most conformable to the spirit of this code."
[fn. 7]  7. Section 3302 of the Public Resources Code provides: "Upon complaint being made to the director by any person operating in any oil field that there is occurring or threatened an unreasonable waste of gas in any field or fields, and when a petition is filed with the director requesting that a hearing be held to consider whether such waste is occurring or threatened, if it appears to the director that there is probable cause for such complaint, he shall order the supervisor to hold such a hearing and to fix a time and place therefor. A hearing may also be ordered by the director on the application of the supervisor."
