
126 N.W.2d 427 (1964)
Marvin McCARL, Appellant,
v.
Phillip FERNBERG, Appellee.
No. 51179.
Supreme Court of Iowa.
February 11, 1964.
Joseph L. Phelan, Fort Madison, for appellant.
Hirsch, Riepe & Wright, Burlington, for appellee.
HAYS, Justice.
Plaintiff alleges an oral contract of employment with defendant and in an action for a declaratory judgment seeks a determination of his rights under the contract and for money damages. The defendant filed a motion to dismiss the petition for the reason that it does not seek a declaration of present right, status or relationship as contemplated by Rule 261, R.C.P., 58 I.C.A., and for the further reason that it fails to state a cause of action against the defendant. The trial court overruled the motion as to the first proposition and sustained it on the ground that the petition failed to state any grounds upon which plaintiff could obtain the relief asked. Plaintiff appeals.
Rule 261, R.C.P., provides "Courts of record * * * shall declare rights, status, and other legal relations whether or not further relief is or could be claimed. * * *"
Rule 262, R.C.P., states: "Any person interested in a contract, oral or written, * * * may have determined any question of the construction or validity thereof or arising thereunder, and obtain a declaration of rights, status or legal relations thereunder."
*428 Rule 263, R.C.P., says "A contract may be construed either before or after there has been a breach thereof."
Rule 104, R.C.P., in part provides: "Every defense in law or fact to any pleading must be asserted in the pleading responsive thereto, if one is required, or if none is required, then at the trial, except that: * * * (b) Failure to state a claim on which any relief can be granted, may be raised by motion to dismiss such claim, filed before answer." A motion to dismiss filed under this rule admits all material facts well pleaded whether the action be the usual one or be for a declaratory judgment under rule 261. Schultz v. Brewer, 244 Iowa 21, 55 N.W.2d 561; Hartford Acc. & Ind. Co. v. O'Connor-Regenwether Post No. 3633, Veterans of Foreign Wars, 247 Iowa 168, 73 N.W.2d 12; 26 C.J.S. Declaratory Judgments § 142 b; 16 Am.Jur. Declaratory Judgments, sec. 67.
The basic and fundamental requirement under rule 261 is that the facts alleged in the petition seeking such relief must show there is a substantial controversy between the parties having adverse legal interests of sufficient immediacy and reality to warrant a declaratory judgment. There must be a justiciable controversy as distinguished from a mere abstract question. Melsha v. Tribune Publishing Co., 243 Iowa 350, 51 N.W.2d 425; Wesselink v. State Department of Health, 248 Iowa 639, 80 N.W.2d 484; Wright v. Thompson, Iowa, 117 N.W.2d 520. In Hartford Acc. & Ind. Co. v. O'Connor-Regenwether Post, supra, this court recognized as a well pleaded fact and admitted by the motion to dismiss, an allegation that there is a present dispute between the parties as to their contractual rights and held a cause of action was stated within the purview of rules 261-263, R.C.P.
Turning now to the instant case. Plaintiff's petition alleges an oral contract between him and defendant whereby he was employed as a truck driver and laborer for defendant. That while plaintiff was operating defendant's truck with defendant's consent, an accident occurred in which a child was killed. Suit for damages on account thereof was filed against plaintiff and defendant. Defendant's insurer, based upon defendant's denial that plaintiff was driving his truck with his consent, reported no coverage for liability, as to the plaintiff, to the State Department of public safety which revoked plaintiff's license to operate a truck. The action was dismissed upon a settlement with defendant's insurer. Thereafter in violation of the contract defendant dismissed plaintiff from his employ to his damage and for which defendant refuses to pay. The petition alleges that a controversy exists between plaintiff and defendant as to their rights and duties under said oral agreement and asks a declaration of their rights thereunder and for a money judgment.
Viewing plaintiff's petition, vague and confusing as it is, in the light of the above stated rules pertaining to declaratory judgments, we think a cause of action within the purview of such type of action, was stated and that the trial court overlooked the difference between a motion to dismiss as is generally contemplated by rule 104(b) and as the same is applicable under proceedings under rule 261. It decided the issues on whether or not plaintiff was, under the pleadings, entitled to the relief demanded, i. e., a money judgment and overlooked the rule that one may have a declaratory judgment even though such judgment may be unfavorable and deny to him the relief asked. 26 C.J.S. Declaratory Judgments §§ 142 a and 142 b; Wright v. Thompson, supra. The petition alleges that an oral contract exists between plaintiff and defendant, the terms of which are in dispute and asks that rights thereunder be determined. Such states a cause of action as contemplated by rule 261 and the trial court erred in sustaining the motion to dismiss.
Reversed and remanded.
All Justices concur.
