Me COY, J.
[i] On the 4th day of June, 1913, there was made and entered in the circuit court of McPherson County, an order sustaining a demurrer to plaintiffs complaint; demurrer theretofore having been interposed on the ground that said complaint did not contain a sufficient statement of facts to constitute a cause of action. Thereafter, on the 27th day of June, in another county of the same circuit, before the s'ame judge, motion was made to the court to set aside the said order sustaining the said demurrer upon the ground that the court erred in sustaining the said demurrer to plaintiff’s complaint. Defendant appeared and resisted said motion on the ground, 'among others, that plaintiff had his remedy by appeal, if dissatisfied with such order, and that appeal was the only legal method of attacking such order. On the hearing of said motion, the court vacated the order sustaining the demurrer, to which action of the court defendant duly excepted, and now assigns such ruling as error. We are of the opinion that the court had no power or authority to vacate or reverse the order sustaining the demurrer. The determination of a demurrer is a trial of an issue of law. The court in this case had jurisdiction of the parties and subject matter at the time it sustained the demurrer to the complaint. It was a judgment erroneous, if at all, only as a matter of law.
The remedy by motion is available only in case of irregular and void judgments (irregular and void by reason of the want of jurisdiction or want of adherence to- some essential legal procedure), and cannot be resorted to as a means of enabling the court to review, revise,- or correct errors of law into which it may have fallen. That a judgment is erroneous as a matter of law is ground for appeal; but it is no ground for setting aside the judgment on motion. A motion to set aside -a judgment cannot be made to perform -the office of an appeal. Black on Judgments, §329; State v. Donovan, 10 N. D. 203, 86 N. W. 709; Proudzinski v. Garbutt, 9 N. D. 239, 83 N. W. 23; Garr, Scott & Co. v. Spaulding, 2 N. D. 414, 51 N. W. 867; Schaettler v. Gardiner, 47 N. Y. 404; Kamp v. Kamp, 59 N. Y. 212; Hartshorn v. C., M. & St. P. Ry., *38923 Wis. 695; Spafford v. Jaynesville, 15 Wis. 474; Bank of U. S. v. Moss, 6 How. 31, 12 L. Ed. 331. See note to Furman v. Furman, 153 N. Y. 309, 47 N. E. 577, 60 Am. St. Rep. 652; 14 Ency. Pl. & Pr. 88. In Spafford v. Janesville it is held that a motion to correct an error in law in a decision on a demurrer cannot take the place of an appeal.
[2] AVe hold that the order vacating the order sustaining the demurrer is an appealable order.
The order appealed from is reversed, and plaintiff given 30 days from the filing of the remittitur in which to serve an amended complaint, if he so desires.