
229 Cal.App.2d 197 (1964)
ZELWYN ALEXANDER AARONS, Plaintiff and Appellant,
v.
ROSE BRASCH, Defendant and Respondent.
Civ. No. 21430. 
California Court of Appeals. First Dist., Div. Two.  
Aug. 17, 1964.
 Barnett & Wood and Edmund S. Barnett for Plaintiff and Appellant.
 Abraham Setzer for Defendant and Respondent. *198
 SHOEMAKER, P. J.
 This is an appeal by plaintiff Zelwyn Aarons from a judgment for defendant Rose Brasch, formerly Rose Aarons, entered upon the granting of her motion for judgment on the pleadings.
 The complaint alleged the existence of three prior judgments or decrees, all of which were incorporated by reference into the complaint, and all of which were in favor of defendant and against plaintiff. The first of these judgments was an interlocutory decree of divorce entered on March 7, 1947; the second, a final decree of divorce entered on April 12, 1948, and the third, a judgment entered on March 9, 1962, whereby plaintiff was ordered to pay defendant a designated sum of money which had been awarded her by the 1947 and 1948 decrees, and which was still unpaid and owing. The complaint further alleged that on February 19, 1962, plaintiff had filed a petition in bankruptcy in the federal district court, but that defendant nevertheless threatened to execute upon and attempt to enforce the 1962 judgment. Plaintiff alleged the existence of an actual controversy between the parties in that it was his contention that the 1962 judgment, which was based upon the 1947 and 1948 decrees, was a money judgment and as such dischargeable under section 17 of the Bankruptcy Act (11 U.S.C.A.  35), whereas defendant contended that the 1962 judgment was for alimony, support or maintenance and therefore not so dischargeable. Plaintiff prayed for an order restraining defendant from attempting to enforce her rights as a judgment creditor and for a judicial declaration that all three judgments or decrees in defendant's favor were dischargeable under the Bankruptcy Act.
 Defendant filed her answer to the complaint, and moved for judgment on the pleadings. This motion was based upon the ground that the complaint failed to state a cause of action for the reasons, among others, that the prior judgments and decrees were res judicata of the alleged controversy, and that the monetary obligation which remained unsatisfied under said judgments and decrees was not dischargeable in bankruptcy.
 The court granted defendant's motion for judgment on the pleadings on the grounds that the complaint did not state a cause of action, that the 1947, 1948 and 1962 judgments and decrees were res judicata of every issue purportedly raised by the complaint, and that the unsatisfied portion of said judgments and decrees did not constitute a money judgment dischargeable under section 17 or any other section of the Bankruptcy Act. *199
 Although the parties address the bulk of their arguments to the propriety of the court's finding of res judicata, it is unnecessary to review these contentions because the judgment may clearly be upheld on the basis of the court's alternative finding that the unsatisfied portion of the 1947, 1948 and 1962 judgments and decrees did not constitute a money judgment dischargeable under the Bankruptcy Act.
 Appellant strongly urges that since this is a declaratory action, the matter should not have been disposed of upon motion, but only after hearing and the taking of evidence. In this regard, the California courts have repeatedly held that a complaint which alleges the existence of an actual controversy and prays for an adjudication of rights and duties pertaining thereto is legally sufficient to entitle the plaintiff to declaratory relief, even if it is apparent that the controversy must be adjudicated in a manner unfavorable to the plaintiff. (2 Witkin, Cal. Procedure, Pleading,  456; Maguire v. Hibernia Sav. & Loan Soc. (1944) 23 Cal.2d 719, 729 [146 P.2d 673, 151 A.L.R. 1062]; Columbia Pictures Corp. v. DeToth (1945) 26 Cal.2d 753, 760 [161 P.2d 217, 162 A.L.R. 747]; Bennett v. Hibernia Bank (1956) 47 Cal.2d 540, 549-550 [305 P.2d 20].) This does not mean, however, that the court may not dispose of an unmeritorious controversy by granting judgment on the pleadings in favor of the defendant. (2 Witkin, Cal. Procedure, Pleading,  456 [1963 Supp.].) [1] To the contrary, it is now established in this state that the trial court may adjudicate the parties' respective contentions upon a motion for judgment on the pleadings and may enter a judgment expressly decreeing that the plaintiff is not entitled to the favorable declaration which he seeks. (Essick v. City of Los Angeles (1950) 34 Cal.2d 614, 624-625 [213 P.2d 492]; Wilson v. Board of Retirement (1957) 156 Cal.App.2d 195, 199-203 [319 P.2d 426].) It follows that the procedure utilized by the trial court was entirely proper and that the judgment for respondent must be upheld if the court was correct in finding that the unsatisfied portion of the 1947, 1948 and 1962 judgments and decrees did not constitute a money judgment dischargeable under the Bankruptcy Act.
 In reviewing the sufficiency of this finding, it must be noted that the trial court had before it copies of all three judgments and decrees and a copy of the complaint in the 1947 divorce action. The first three documents were, as above noted, incorporated by reference into appellant's complaint. Although the latter document was incorporated by *200 reference into respondent's answer, the trial court was nevertheless entitled to consider it in ruling on the motion for judgment on the pleadings. [2] Where a document is attached to the answer as an exhibit, the authenticity and due execution of the document are deemed admitted unless denied by an opposing affidavit (Code Civ. Proc.,  448), and the court may properly consider such document in ruling on a motion for judgment on the pleadings. (De Gonia v. Building Material etc. Union (1957) 155 Cal.App.2d 573, 577 [318 P.2d 486]; Shabrick v. Moore (1961) 195 Cal.App.2d 56, 59-60 [15 Cal.Rptr. 310].) In the instant case, appellant filed no opposing affidavit.
 Pursuant to her complaint in the 1947 divorce action, respondent prayed for a divorce from appellant on the ground of extreme cruelty; for an award of all the parties' community property; for alimony, support and maintenance, pendente lite and permanently; and for counsel fees and costs. As a second cause of action, respondent alleged that appellant, for a valuable consideration, had executed a promissory note in her favor in the principal amount of $1,000, with six per cent interest from June 1, 1943; that said note had been due and owing since June 1, 1943, and that she was accordingly entitled to a money judgment for the principal and interest due thereunder.
 The interlocutory decree of divorce, entered on March 7, 1947, recited that appellant's default had been duly entered and that the court found, upon evidence presented by respondent, that all of the allegations of the complaint were true and that respondent was entitled to a divorce on the ground of extreme cruelty. The decree awarded respondent all of the community property of the parties; the sum of $1,225.96, which the court found to be the amount of principal and interest due under the promissory note; costs in the sum of $12.75; counsel fees in the sum of $1,000; and an additional lump sum award of $7,500.  [fn. 1]
 The final decree, entered on April 12, 1948, granted respondent a divorce on the ground of extreme cruelty and awarded her all of the parties' community property. The court found that appellant had paid respondent $5,000 in *201 partial satisfaction of the monetary awards under the interlocutory decree; that the $5,000 had been applied so as to pay in full the principal and interest due on the promissory note, respondent's attorney's fees and costs, $2,020.07 toward the $7,500 award, and interest to April 8, 1948 on all of these items; that there remained due and owing $5,480 of the principal of the $7,500 award, interest on said sum from April 8, 1948, and costs accrued since March 7, 1947.
 On March 9, 1962, respondent obtained a default judgment based upon the 1947 and 1948 decrees. Pursuant to this judgment, appellant was ordered to pay respondent $10,821.72, which sum was comprised of the principal remaining unpaid upon the $7,500 award plus 7 per cent interest thereon from April 8, 1948.
 [3] It is this judgment in the amount of $10,821.72 which appellant contends is dischargeable under section 17 of the Bankruptcy Act. Respondent, on the other hand, asserts that this judgment is expressly rendered nondischargeable by the following language of that section: "(a) A discharge in bankruptcy shall release a bankrupt from all of his provable debts, whether allowable in full or in part, except such as ... are liabilities ... for alimony due or to become due, or for maintenance or support of wife or child. ..." Respondent's position is clearly correct.
 Civil Code, section 139, provides in relevant part that "In any interlocutory or final decree of divorce ... the court may compel the party against whom the decree ... is granted to make such suitable allowance for support and maintenance of the other party for his or her life, or for such shorter period as the court may deem just, having regard for the *202 circumstances of the respective parties. ..." It is settled that the award contemplated by this section is based upon the theory "that the husband entered upon an obligation which bound him to support his wife during the period of their joint lives, that by his own wrong he has forced her to sever the relation which enabled her to compel the performance of this duty, and that he is required to make compensation for the offense committed by him which has deprived her of the benefit of the obligation." (Arnold v. Arnold (1946) 76 Cal.App.2d 877, 885-886 [174 P.2d 674]; Webber v. Webber (1948) 33 Cal.2d 153, 157-158 [199 P.2d 934]; Haldeman v. Haldeman (1962) 202 Cal.App.2d 498, 507-508 [21 Cal.Rptr. 75].) It is also settled that the court may provide for such an allowance by requiring the payment of a sum in gross. (Robinson v. Robinson (1889) 79 Cal. 511, 515-516 [21 P. 1095]; Honey v. Honey (1923) 60 Cal.App. 759, 761-762 [214 P. 250]; Scheibe v. Scheibe (1943) 57 Cal.App.2d 336, 343 [134 P.2d 835].)
 [4] In the present case, respondent's complaint for divorce contained a prayer for "alimony, support and maintenance, pendente lite, and permanently." Pursuant to the 1947 interlocutory decree of divorce, respondent was awarded $7,500 as "compensation" for the many years during which she had struggled to provide the means by which appellant could pursue academic studies and thereby attain fruits and accumulations in which, by virtue of appellant's cruelty, she would not be entitled to share. Although the decree does not expressly refer to this award as "alimony," "support" or "maintenance," any such designation would appear superfluous in view of the clear import of the language above summarized. Moreover, appellant has been unable to suggest any other basis for the award. Since the interlocutory decree awarded respondent all of the community property, it is apparent that the $7,500 award could not have been intended as a property division, and it follows that it must of necessity have constituted an award of alimony, support or maintenance, which were the only items prayed for in the complaint which were not dealt with in other portions of the interlocutory decree.
 Judgment affirmed.
 Agee, J., and Taylor, J., concurred.
NOTES
[fn. 1]  1. The portion of the decree pertaining to this last award is as follows: "It appearing to the Court and the Court does find that during the coverture of the parties hereto the plaintiff herein Rose Aarons, for many years did engage in various employments and labor and while living in great privation and by self denial and deprivation thereby earned and provided the means by which the defendant above named was enabled to puruse [sic] academic and vocational studies and training whereby he received the degree of Master of Philosophy and Doctor of Medicine, and to become so trained and skilled; that the plaintiff has not shared in the fruits and accumulations of such education, training and skills of said defendant; that plaintiff's earnings and contributions during said period were in excess of Ten Thousand and no/100 ($10,000.00) Dollars, and that said defendant during said period did not engage in any sustained employment or effort to support plaintiff or himself or to maintain such studies and training, and by reason of the premises, as and for compensation therefore to the plaintiff and by reason of said defendant's extreme cruelty to plaintiff and in view of the potential earning power now and in the future to be possessed and enjoyed by the defendant by reason of plaintiff's efforts in his behalf as aforesaid, the Court does hereby award plaintiff the gross sum of Seventy-five Hundred ($7,500.00) Dollars, and does order, adjudge and decree that the defendant pay said sum to plaintiff, in additional [sic] to all other awards, sums or amounts herein otherwise awarded, adjudged, ordered and decreed ..."
