
35 Cal.2d 379 (1950)
EDWARD G. ROBINSON et al., Petitioners,
v.
SUPERIOR COURT OF LOS ANGELES COUNTY et al., Respondents; MICHEL KRAIKE, Real Party in Interest.
L. A. No. 21188. 
Supreme Court of California. In Bank.  
May 9, 1950.
 Simon, Fox & Fraider and Stanley E. Fox for Petitioners.
 Pauline Nightingale, Edward M. Belasco and Leon H. Berger, Amici Curiae on behalf of Petitioners.
 Harold W. Kennedy, County Counsel, and Wm. E. Lamoreaux, Deputy County Counsel, for Respondents.
 Julian C. Sorin for Real Party in Interest.
 GIBSON, C.J.
 A dispute arose between Michel Kraike, an artist, and petitioners, who are executors of the estate of F. W. Vincent, deceased, an employment agent, over commissions claimed to be due under a written agency contract. The dispute was submitted to the Labor Commissioner for settlement, and after a hearing the petitioners were awarded the sum of $500. Kraike did not seek a hearing de novo in the superior court, as allowed by section 1647 of the Labor Code,  [fn. *] and after the 10 days in which he could have sought such a hearing had passed, petitioners moved the superior court under section 1287 of the Code of Civil Procedure  [fn. *] for an order confirming the commissioner's award. The court denied the motion on the ground that the provisions of section 1287 of the Code of Civil Procedure authorizing judicial confirmation of the awards of arbitrators cannot be applied to an award of the Labor Commissioner and that the only remedy available to *382 petitioners was an independent action on the award as an obligation created by law. This proceeding in mandate was then brought to compel the trial court "to take jurisdiction of the motion for an order confirming the commissioner's award and to render a judgment thereon either confirming, modifying, correcting or vacating the award."
 In considering the availability of the writ the first question to be determined is whether petitioners had another plain, speedy, and adequate remedy at law. (Code Civ. Proc.,  1086.) The appealability of an order denying a motion for confirmation of an award is not clearly established by the relevant statutes or by the decisions construing them. Section 963 of the Code of Civil Procedure provides that an appeal may be taken from a final judgment entered in a special proceeding, but it has been held that the application of this section is restricted by section 1293 of the Code of Civil Procedure which provides that "an appeal may be taken from an order confirming, modifying, correcting or vacating an award, or from a judgment entered upon an award, as from an order or judgment in an action." (Jardine-Matheson Co., Ltd. v. Pacific O. Co., 100 Cal.App. 572, 576-577 [280 P. 697].)
 [1] Although an order denying a motion for confirmation is not expressly enumerated therein, section 1293 has been liberally construed to allow an appeal from an order made after completion of arbitration which in effect dismisses the proceeding before the court. (See Pleaters etc. Assn. v. Superior Court, 114 Cal.App. 35, 36 [299 P. 555], order dismissing application for confirmation with prejudice held equivalent to order vacating award; Glesby v. Balfour, Guthrie & Co., Ltd., 63 Cal.App.2d 414, 417 [147 P.2d 60], order denying motion to vacate an award held equivalent to order confirming award.) An order directing parties to proceed to arbitration was held nonappealable in Jardine-Matheson Co., Ltd. v. Pacific O. Co., 100 Cal.App. 572 [280 P. 697], but that case is distinguishable from the cases cited above and from the situation presented here. In holding the order nonappealable in the Jardine case, the court stated that the purpose of section 1293 was to permit appeals only after arbitration has been completed and an award made, and that to permit an appeal at an earlier stage of the proceedings would result in undue delay and defeat the purpose of the arbitration statutes.
 [2] In the present case the order was made after completion of the proceedings before the commissioner, and in effect constituted a dismissal of the application for confirmation of *383 the award. Under the liberal construction which has been given section 1293, the order denying the motion to confirm the award, while not a decision on the merits, may be treated, for purposes of appeal, as being equivalent to an order vacating the award, and it is therefore appealable. [3] However, in view of the uncertainty which has existed heretofore with respect to appealability of orders of this type, we should not refuse to allow the writ to be used to test the issue before us solely because we have now resolved that uncertainty by holding that petitioners had an adequate remedy by appeal from the order in question.
 The next question to be considered is whether the trial court has failed or refused to perform a duty which may be enforced by mandate. It is clear from the record that the motion for an order confirming the award was denied on the sole ground of lack of jurisdiction and that the trial court did not determine the merits of the application. [4] The law is well settled that a trial court is under a duty to hear and determine the merits of all matters properly before it which are within its jurisdiction and that mandate may be used to compel the performance of this duty. This is so even where the trial court's refusal to pass on the merits is based on the considered but erroneous belief that it has no jurisdiction as a matter of law to grant the relief requested. As stated in Temple v. Superior Court, 70 Cal. 211, 212 [11 P. 699], "the court cannot, by holding without reason that it has no jurisdiction of the proceeding, divest itself of jurisdiction, and evade the duty of hearing and determining it." Mandate will issue to compel a hearing and determination of the merits where the court has merely sustained an objection on jurisdictional grounds and left the proceeding pending. (Lissner v. Superior Court, 23 Cal.2d 711 [146 P.2d 232]; Miller v. Municipal Court, 22 Cal.2d 818 [142 P.2d 297]; Conklin v. Superior Court, 1 Cal.2d 601 [36 P.2d 386].) [5] The writ is also available where the trial court has disposed of a matter by an order dismissing it or denying relief on the sole ground of lack of jurisdiction. (Sampsell v. Superior Court, 32 Cal.2d 763 [197 P.2d 739]; Stewart v. Superior Court, 29 Cal.2d 63 [172 P.2d 683]; Kotenkamp v. Superior Court, 16 Cal.2d 696 [108 P.2d 1]; Hennessy v. Superior Court, 194 Cal. 368 [228 P. 862]; Golden Gate Tile Co. v. Superior Court, 159 Cal. 474 [114 P. 978]; Cahill v. Superior Court, 145 Cal. 42 [78 P. 467]; Temple v. Superior Court, 70 Cal. 211 [11 P. 699].) Thus, there is no distinction, insofar as the availability of the writ is concerned, *384 between cases where the court merely refuses to proceed because of its erroneous belief that it has no jurisdiction, and those in which the court makes a ruling disposing of the matter on the sole ground it has no jurisdiction. In either case if the effect is to preclude a hearing and judgment on the merits of a matter properly before the court, and there is no other adequate remedy, mandate will lie to test the question of jurisdiction.
 The case of Brock v. Superior Court, 119 Cal.App. 5 [5 P.2d 659], is in conflict with the cases cited above. An action was brought by Mrs. Brock against her former husband for the support of their minor child, and the trial court made an order denying the requested relief "on account of this Court not having jurisdiction to award temporary attorney fees, costs, or support on two grounds; that the child is not within the jurisdiction of this Court, also that provisions in Section 137, Civ. Code, in re Attorney's fees, costs and support money do not apply in this case." A petition for a writ of mandate to compel the trial court to hear and determine the matter was denied with a short opinion which was filed four days after the application for the writ was made, and which cited no authority in support of its holding that the writ was not available to test the question of jurisdiction. The petition might have been denied upon the ground that there was another adequate remedy at law by appeal from the order, but this was not the basis of the decision. Instead, it was held that the trial court "did not deny its jurisdiction to pass upon the application. It did pass upon and determine said application, but refused the requested allowance, because the court was of the opinion that it did not have the authority to make such allowance to a child not residing in this state and not present in this state, in an action to compel a father to support his child. If the court erred in this conclusion (which we do not decide), it was only an error made by the court in the exercise of its jurisdiction. It was not a refusal to act upon the merits of the matter presented."
 If, by the statement that there was no "refusal to act upon the merits," the Brock case means that the trial court did not refuse to pass upon and determine its own jurisdiction, then the opinion incorrectly uses the term "merits." [6] It is well settled that a dismissal of a proceeding or a denial of relief on the sole ground of lack of jurisdiction is not a decision on the merits. (See Hogeberg v. Industrial Acc. Com., 201 Cal. 169, 182-183 [256 P. 413]; Slaker v. McCormick-Saeltzer *385 Co., 179 Cal. 387, 389 [177 P. 155]; Helvey v. Castles, 73 Cal.App.2d 667, 672 [167 P.2d 492].) If the opinion means that the trial court did not refuse to pass upon and exercise its discretion with respect to other questions presented, such as the necessity and reasonableness of the allowances, then the appellate court did not carefully examine the record before it. The record shows that the only evidence heard or considered by the trial court was the stipulated fact "that the child was not then a resident of or physically present in the state of California." It is clear that the trial court passed only on the question of its jurisdiction and that it disposed of the request for allowances for support, etc., on the sole ground that it was without jurisdiction to hear and determine the merits of the application.
 [7] In Sampsell v. Superior Court, 32 Cal.2d 763, 770 [197 P.2d 739], we erroneously assumed because of statements in the Brock opinion that the trial court in that case had given the petitioner a hearing on the merits, and there is language in the Sampsell opinion which suggests that if such a hearing has been had, mandate will not lie to compel a decision on the merits. This is not a correct statement of the rule. If the court has jurisdiction of a case the parties are entitled to something more than a hearing on the merits--they are entitled to a decision thereon. (See Cahill v. Superior Court, 145 Cal. 42 [78 P. 467].) One of the fundamental aims of the law is to secure to a litigant a judgment on the merits of a matter properly brought before the court, and one of the ancient offices of the writ of mandate was to compel a court to hear and decide the merits of a matter within its jurisdiction. (See 35 Am.Jur. 25.)
 [8] In refusing to permit mandate to be used to test the jurisdictional question, the Brock case is in conflict with the long line of decisions beginning with Temple v. Superior Court, 70 Cal. 211 [11 P. 699], cited above, and with the weight of authority in this country, holding that the writ will lie to review orders dismissing a proceeding or denying relief on the sole ground of lack of jurisdiction, if there is no other adequate remedy. (See cases in other jurisdictions collected in 4 A.L.R. 582; 82 A.L.R. 1163.)
 The Brock case was followed in Hayward v. Superior Court, 130 Cal.App. 607, 609, 612 [20 P.2d 348], and Thomas v. Superior Court, 4 Cal.App.2d 356, 359-360 [41 P.2d 220], *386 which refused to permit the use of mandate to review orders of trial courts dismissing proceedings on the sole ground of lack of jurisdiction. The opinions in those cases contain such statements as "It is elementary that a writ of mandate is not a writ of error" (Thomas v. Superior Court, supra, at p. 359) and "mandate cannot be employed as corrective of error." (Hayward v. Superior Court, supra, at p. 610.) Such statements are too broad and were long ago characterized as inaccurate and misleading. (See Wood v. Strother, 76 Cal. 545, 548-554 [18 P. 766, 9 Am.St.Rep. 249]; In re Ford, 160 Cal. 334 [116 P. 757, Ann.Cas. 1912D 1267, 35 L.R.A.N.S. 882]; MacPherson v. Superior Court, 22 Cal.App.2d 425, 432-434 [71 P.2d 91].) It is obvious that if the error involves a breach of what has been deemed a "clear legal duty" and there is no other adequate remedy, mandate will lie. (See Brown v. Superior Court, 34 Cal.2d 559, 561 [212 P.2d 878]; Betty v. Superior Court, 18 Cal.2d 619, 622 [116 P.2d 947].) As we have seen, there is a clear duty on a court to hear and determine the merits of all matters within its jurisdiction and properly before it, and performance of this duty is compellable by mandate. Any other rule would be unjust where the order disposing of the proceeding is nonappealable, because the aggrieved party would have no way of correcting the trial court's error and obtaining a decision on the merits. (See Katenkamp v. Superior Court, 16 Cal.2d 696, 698 [108 P.2d 1]; Cahill v. Superior Court, 145 Cal. 42, 44 [78 P. 467].)
 The case of Lincoln v. Superior Court, 22 Cal.2d 304 [139 P.2d 13], does not conflict with the position we have taken here. The order of dismissal there involved was not based expressly on the ground of lack of jurisdiction, and it appeared that the trial court had heard and determined the matter before it on its merits. Moreover, the opinion notes that petitioner was not entitled to mandate because he had an adequate remedy by appeal. There is language in the opinion, however, which would appear to suggest that mandate will not lie to compel a court to hear and determine the merits of a matter if it has made an order within its jurisdiction which disposes of the proceeding. (See 22 Cal.2d 304, 309-310, 314-315.)
 The cases of Brock v. Superior Court, 119 Cal.App. 5 [5 P.2d 659], Hayward v. Superior Court, 130 Cal.App. 607 [20 P.2d 348], and Thomas v. Superior Court, 4 Cal.App.2d 356 [41 P.2d 220], are disapproved, and any language in Lincoln v. Superior Court, supra, and Sampsell v. Superior Court, *387 supra, which is not in accord with the views expressed herein is likewise disapproved.
 As before stated, the motion for an order confirming the award of the Labor Commissioner was denied on the sole ground of lack of jurisdiction, and petitioners are, therefore, entitled to mandate if respondent court had jurisdiction to entertain and determine their motion.
 [9a] It is contended that section 1287 of the Code of Civil Procedure providing for judicial confirmation of the awards of arbitrators has no application to awards of the Labor Commissioner and accordingly that the trial court was without jurisdiction to entertain the motion for an order confirming the award here involved. Although the Labor Commissioner is not expressly mentioned in sections 1280 to 1293 of the Code of Civil Procedure relating to arbitration, the provisions therein apply to written agreements to submit controversies to arbitrators for settlement, and there appears to be no good reason why the method of obtaining judicial confirmation of awards provided for in section 1287 should not apply to awards made by the Labor Commissioner. [10] Under the Labor Code, a contract between an employment agency and an applicant for employment may provide for reference of controversies arising thereunder either to the Labor Commissioner (Lab. Code,  1626, 1647) or to private arbitration (Lab. Code,  1647.5). In the settlement of disputes submitted to him, the Labor Commissioner acts as an arbitrator, and the powers he exercises are similar to those which may be conferred on private arbitrators pursuant to section 1647.5. (See Garson v. Division of Labor Law Enforcement, 33 Cal.2d 861, 864- 866 [206 P.2d 368].)
 Under the Code of Civil Procedure parties may agree to name a single arbitrator, and there is no restriction as to what persons may act in that capacity. (Code Civ. Proc.,  1283, 1286.) The sole requirement for a valid and enforceable arbitration agreement is that it must be in writing and must not apply to disputes arising out of contracts "pertaining to labor." (Code Civ. Proc.,  1280.) [11] A contract between an artist and an employment agency is not a contract pertaining to labor within the inhibition of section 1280. (See Kerr v. Nelson, 7 Cal.2d 85, 88 [59 P.2d 821]; Universal Pictures Corp. v. Superior Court, 9 Cal.App.2d 490, 492-495 [50 P.2d 500].) [12] The agency contract in the present case is in writing, it provides that all disputes arising thereunder *388 shall be submitted to the Labor Commissioner for settlement, and it therefore meets the requirements of section 1280.
 [13] The fact that the Labor Code provides that a party aggrieved by the commissioner's decision may obtain a complete new hearing in the superior court (Lab. Code,  1647) affords no reason why the party prevailing before the commissioner should not be able to get judicial confirmation of the award under section 1287 of the Code of Civil Procedure, if the other party does not take advantage of the de novo procedure. Nor should the fact that the successful party may bring an independent action at law to enforce the award deprive him of the more expeditious procedure provided by statute. There appears to be no justification for saying that the awards of the Labor Commissioner are not entitled to as speedy and summary method of enforcement as those of private arbitrators if no de novo hearing has been sought. Moreover, such a speedy method of enforcement of awards might assist the Labor Commissioner in curtailing undesirable activities of employment agencies under his supervision.
 We find nothing in the statutes which shows that the Legislature intended that the Labor Commissioner's awards should not be enforceable under Code of Civil Procedure section 1287, in the same manner as awards of private arbitrators. It is true that the arbitration sections of the Code of Civil Procedure are expressly made applicable by Labor Code section 1647.5 if the parties agree to private arbitration, and no similar provision is made where the dispute is referred to the Labor Commissioner. However, Labor Code section 1647.5 was added in 1939, two years after the decision in Collier & Wallis, Ltd. v. Astor, 9 Cal.2d 202 [70 P.2d 171], where it was held that no suit could be brought on employment agency contracts until disputes arising thereunder had been referred to the Labor Commissioner. Thus it appears that section 1647.5 was added to relieve the burden on the Labor Commissioner, and to give the parties more freedom in the choice of persons to whom disputes could be referred.
 [9b] Accordingly section 1287 of the Code of Civil Procedure may properly be applied to awards of the Labor Commissioner if no hearing de novo has been sought, and respondent court had jurisdiction to hear and determine petitioners' motion for an order confirming the award.
 Let the writ issue as prayed.
 Shenk, J., Edmonds, J., Carter, J., Traynor, J., and Spence, J., concurred. Schauer, J., concurred in the judgment.
NOTES
[fn. *]  *. " 1647. In all cases of controversy arising under this chapter the parties involved shall refer the matters in dispute to the Labor Commissioner, who shall hear and determine the same, subject to appeal within ten days after determination, to the superior court where the same shall be heard de novo. To stay any award for money, the party aggrieved shall execute a bond approved by the superior court in a sum not exceeding twice the amount of the judgment. In all other cases the bond shall be in a sum of not less than one thousand dollars and approved by the superior court." (Italics added.)
[fn. *]  *. " 1287. At any time within three months after the award is made, unless the parties shall extend said time in writing, which award must be in writing and acknowledged or proved in like manner as a deed for the conveyance of real estate, and delivered to one of the parties or his attorney, any party to the arbitration may apply to the superior court of the county or city and county in which said arbitration was bad for an order confirming the award; and thereupon said court must grant such an order unless the award is vacated, modified or corrected, as prescribed in the next two sections. Notice in writing of the motion must be served upon the adverse party or his attorney five days before the hearing thereof."
