
57 Wis.2d 417 (1973)
204 N.W.2d 470
THEUNE, Respondent,
v.
CITY OF SHEBOYGAN and another, Appellants.
No. 142.
Supreme Court of Wisconsin.
Submitted February 1, 1973.
Decided February 27, 1973.
*419 For the appellants the cause was submitted on the brief of Clarence H. Mertz, city attorney.
For the respondent the cause was submitted on the brief of Chase, Olsen & Kloet, attorneys, and Alvin R. Kloet of counsel, all of Sheboygan.
Submitted under sec. (Rule) 251.54 February 1, 1973.
HEFFERNAN, J.
The purpose of a demurrer is to test the legal sufficiency of the pleading. Interstate Fire & *420 Casualty Co. v. Milwaukee (1970), 45 Wis. 2d 331, 333, 173 N. W. 2d 187.
Upon demurrer, a court is required to give liberal construction to the allegations of the complaint, and the demurrer for failure to state a cause of action must be overruled when the complaint expressly or by inference states a cause of action. Chudnow Construction Corp. v. Commercial Discount Corp. (1970), 48 Wis. 2d 653, 656, 180 N. W. 2d 697; Volk v. McCormick (1969), 41 Wis. 2d 654, 658, 165 N. W. 2d 185.
When a complaint is tested on demurrer, it is not the duty of the court to hypothesize whether a plaintiff can prove the allegations. It is sufficient that the facts alleged, if proved, spell out a cause of action. Rogers v. Oconomowoc (1962), 16 Wis. 2d 621, 634, 115 N. W. 2d 635.
The trial judge properly applied these tests, and his order overruling the demurrer must be sustained.
Schoonover v. Viroqua (1944), 244 Wis. 615, 619, 12 N. W. 2d 912, points out that a governmental employee who works in excess of his usual day cannot recover for the overtime work in the absence of an express agreement. In this case, however, the plaintiff expressly pleaded General Ordinance No. 173-65-66, sec. 14. That section provides that employees of the city are to receive plus or minus hours to compensate for periods they have worked either more or less than the prescribed work week. Plus hours are to be compensated by time off within one year from the date that such plus hours were earned.
"However, police officers . . . shall be on the first payday after the last pay period in each year, be paid out at the rate determined in subsection 14 (b) for such plus hours as remain to their credit as of that date."
The plaintiff's complaint, therefore, comes within the rule of Schoonover that requires there be an ordinance *421 which, at least, entitles public employees who have worked in excess of the usual work period to be compensated either by additional wages or by compensatory time off. Thus, from the face of the complaint, under the Sheboygan ordinance, police officers are entitled to compensation prescribed by the ordinance whenever they perform overtime work.
The brief of the defendants contends, however, that the "Standby Alert" did not constitute "work" for which the plaintiff is entitled to compensation. The contention is that, to be compensable, the activities of the police officer during the "Standby Alert" had to be those of a police officer in the usual course of his employment. We cannot accept that proposition as a matter of law.
The cases upon which the defendants rely make clear that a determination of the compensability of "standing by" or being "subject to call" can only be made after the evidence has been submitted. The cases relied upon indicate that whether or not the status of awaiting a call to duty constitutes work depends upon the facts of the particular case. There are indeed cases where "they also serve who only stand and wait."
Where an employee sues for wages allegedly earned, he need only plead the ultimate fact that he performed work under a contract or agreement with his employer. Littlefield v. William Bergenthal Co. (1894), 87 Wis. 394, 58 N. W. 743; Joubert v. Carli (1870), 26 Wis. 594. The plaintiff alleged that "said alert is overtime work." That allegation, combined with the underpinning of the ordinance alleged, was all that was necessary to plead a cause of action.
The plaintiff also asks for alternative relief against the common council. He seeks a writ of mandamus to enforce the provisions of secs. 62.13 (7m) and (7n), Stats. Sub. (7n) provides:
"HOURS OF LABOR. The council of every city of the second, third or fourth class, shall provide for a working *422 day of not more than eight hours in each twenty-four except in cases of positive necessity by some sudden and serious emergency, which, in the judgment of the chief of police, demands that such work day shall be extended beyond the eight-hour period at such time; and when such emergency ceases to exist, all overtime given during such emergency, shall be placed to the credit of such policeman, and additional days of rest given therefor."
If the contention is that the statute is inapplicable because "Standby Alert" cannot be considered overtime or work under the statute, the rationale set forth above is applicable. The allegations that the plaintiff performed "overtime work" is sufficient, prima facie at least, to bring the complaint within the terms of sec. 62.13 (7n), Stats.
The defendants do not attack the proposition that mandamus may be properly brought against the common council to compel it to grant rest days when rest days are due, and, accordingly, we do not consider the appropriateness of that remedy. Rather, the defendants argue that the plaintiff has, by the attempted invocation of sec. 62.13 (7n), Stats., stated a separate cause of action, which affects only the common council of the city of Sheboygan, as distinguished from the city of Sheboygan as a municipal corporation. It is argued that the two causes of action cannot be united because of the proscriptions of sec. 263.04:
"Uniting causes of action. The plaintiff may unite in the same complaint several causes of action, whether they be such as were formerly denominated legal or equitable or both. But the causes of action so united must affect all the parties to the action and not require different places of trial, and must be stated separately."
This attack on the complaint misconceives the nature of a cause of action. In Herman v. Felthousen (1902), 114 Wis. 423, 425, 90 N. W. 432, this court stated:
*423 "The test to be applied in order to determine whether a complaint states more than one cause of action, is whether, looking at the whole pleading, there is more than one primary right presented thereby for vindication. There may be many minor subjects, and facts may be stated constituting independent grounds for relief, either as between the plaintiff and all the defendants, or the former and one of the latter, or between defendants, and there be still but a single primary purpose of the suit, with which all the other matters are so connected as to be reasonably considered germane thereto,parts of one entire subject, presenting to the court but one primary ground for invoking its jurisdiction."
The concept of a cause of action was explicated in the case of Caygill v. Ipsen (1965), 27 Wis. 2d 578, 582, 135 N. W. 2d 284. Therein, we accepted the statement of Judge CHARLES E. CLARK, who defined a cause of action as:
"`[A] factual unit, whose limits are determined by the time and sequence and unity of the happenings, rather than [as] . . . potential judicial action.'"
In the case of Rogers v. Oconomowoc (1962), 16 Wis. 2d 621, 115 N. W. 2d 635, these principles were applied to permit the plaintiff to join in one action its claims against municipal officers and the city for injuries arising out of a single accident. We said at page 627:
"Since there is only one subject of controversy (the accident) in the case at bar and only one primary right of plaintiff, there is only one cause of action."
In this case, since it is alleged that compensation is owing for two separate periods of overtime work, there are, in fact, at least two causes of action. The joinder of separate causes of action, however, is not objectionable where, as here, each cause affects both defendants, even though a different remedy is sought.
Whether plaintiff is entitled to additional rest days or additional compensation, or both, and whether relief by *424 mandamus is appropriate is immaterial on demurrer. The prayer for relief is not a part of the complaint, and, even in a case where the plaintiff asks for relief not warranted by the pleaded facts, the demurrer for failure to state a cause of action does not reach that question. Draeger v. John Lubotsky Motor Sales, Inc. (1972), 56 Wis. 2d 419, 420, 202 N. W. 2d 20; Hertz Corp. v. Red Rooster Cheese Co. (1972), 55 Wis. 2d 701, 706, 200 N. W. 2d 603. If the complaint is sufficient to entitle a plaintiff to any relief requested, it is not demurrable.
By the Court.Order affirmed.
