
154 Cal.App.3d 132 (1984)
201 Cal. Rptr. 93
RITA NELSON, Plaintiff and Appellant,
v.
ROBERT C. NEVEL, Defendant and Respondent.
Docket No. 68882.
Court of Appeals of California, Second District, Division Three.
April 5, 1984.
*135 COUNSEL
James P. Francis for Plaintiff and Appellant.
Gayle R. Posner for Defendant and Respondent.
*136 OPINION
ARABIAN, J. 

INTRODUCTION
Plaintiff and appellant, Rita Nelson (appellant), appeals from an order dismissing her complaint against defendant and respondent, Robert C. Nevel (respondent), after respondent's motion for judgment on the pleadings was sustained without leave to amend.

FACTS
(1) Since the trial court rendered judgment for respondent on the pleadings, we must accept the allegations of appellant's complaint as true, determining whether such allegations state, or can be amended to state, a cause of action. (See Sullivan v. Co. of Los Angeles (1974) 12 Cal.3d 710, 714-715, fn. 3 [117 Cal. Rptr. 241, 527 P.2d 865]; 4 Witkin, Cal. Procedure (2d ed. 1971) Proceedings Without Trial, § 161, pp. 2816-2817.) Therefore, we turn to the specific allegations of the complaint.
Appellant filed a complaint against respondent on September 21, 1981, and alleged two separate causes of action. The first cause of action was captioned "Breach of Implied Contract,"[1] and set forth the following facts:
Appellant lived with respondent from January 15, 1969, to February 15, 1978, when the parties separated. During the cohabitation, appellant performed housekeeping services for respondent, acted as his intimate companion, cared for their child and his child of a previous marriage, and contributed to the mutual financial well being of the parties. Appellant performed in such manner with the expectation of both parties that she would share equally in and benefit by all property, both real and personal, acquired by either party during the period of cohabitation.
Through their mutual efforts, the parties acquired a parcel of real property in the City of Lakewood (Lakewood property). Respondent took legal title in his own name. On February 15, 1978, the parties separated and respondent retained possession of the Lakewood property.
Appellant requested the court to order that the Lakewood property be sold and the proceeds be equally divided between the parties. Appellant further *137 requested that she be held harmless from all claims arising from encumbrances placed on the property by respondent.
Respondent's answer generally denied all allegations, and stated as one of several affirmative defenses that appellant's cause of action was barred by the two-year statute of limitations set forth in Code of Civil Procedure section 339.[2]
Less than one week before trial, respondent filed a noticed motion for judgment on the pleadings. On the day of trial, the court ruled the action was barred by the two-year limitations period of section 339 and granted respondent's motion without leave to amend. Appellant's motion for reconsideration of the trial court's ruling was subsequently denied and this appeal followed.

CONTENTIONS
Appellant contends the trial court abused its discretion in sustaining respondent's motion for judgment on the pleadings without leave to amend. She urges that the nature of her complaint is based on the fiduciary relationship between respondent and herself and that she is therefore seeking only equitable relief in the form of a constructive trust. Since she seeks purely equitable relief, appellant urges that the four-year statute of limitations set forth in Code of Civil Procedure section 343[3] applies to this action and thus her lawsuit is not barred.
Respondent contends that appellant's cause of action arises from an implied contract and, therefore, any equitable relief sought by appellant is purely ancillary to her action for breach of implied contract. Respondent argues that even if appellant's prayer for relief could be construed as a request for an accounting, since that remedy is merely ancillary to an action to perfect rights under an implied contract, the action is barred by the two-year limitation period of Code of Civil Procedure section 339. Further, respondent asserts that even if appellant were to amend her complaint to allege the existence of a fiduciary relationship and its subsequent breach, since such allegations constitute constructive fraud, the three-year limitation *138 period of Code of Civil Procedure section 338, subdivision 4, would bar appellant's action.[4]
On appeal we must determine: (1) whether appellant can amend her complaint to plead equitable relief so that the four-year limitation period of Code of Civil Procedure section 343 will apply, and (2) whether the trial court abused its discretion in denying appellant an opportunity to amend her complaint.

DISCUSSION

I.

Appellant's Complaint Can Be Amended to State a Cause of Action Based in Equity.
Issues regarding the legal rights of nonmarital partners have been the subject of heated debate, legislation and litigation during the past decade. In the landmark case, Marvin v. Marvin (1976) 18 Cal.3d 660 [134 Cal. Rptr. 815, 557 P.2d 106], the California Supreme Court addressed the problems which arise when such unmarried partners jointly acquire property. Marvin held that a nonmarital partner has the same right to enforce a contract and to assert an equitable interest in property acquired through his or her efforts as does any other unmarried person. (Id., at p. 684, fn. 24.) The Marvin court also noted that other remedies may be appropriate to protect the parties' lawful expectations, such as: (1) finding an implied contract or an implied agreement of partnership or a joint venture; (2) employing principles of constructive trust or resulting trust; and (3) allowing recovery in quantum meruit for services performed. (Id., at p. 684.) Further, the court noted that the specific mention of those remedies "does not preclude the evolution of additional equitable remedies to protect the expectations of the parties to a nonmarital relationship in cases in which existing remedies prove inadequate; the suitability of such remedies may be determined in later cases in light of the factual setting in which they arise." (Id., at p. 684, fn. 25, italics added.)
(2a) In her complaint, appellant alleged the Lakewood property was acquired through the mutual efforts of the parties during their cohabitation, but legal title was recorded only in respondent's name. In the prayer of her complaint, appellant requested that the Lakewood property be sold and that she be given her interest in the property from the proceeds.
*139 In appellant's oral argument opposing the motion for judgment on the pleadings, and in her opposing papers, appellant urged the facts pleaded in her complaint showed a fiduciary relationship between the parties which provided a basis for equitable relief. She alleged that respondent would be unjustly enriched if he were allowed to retain her interest in the Lakewood property along with his own and requested that the court order an accounting and order respondent to hold the Lakewood property for her under a constructive trust.
(3) In order to fulfill the reasonable expectations of the parties to a nonmarital relationship, a court may, when appropriate, employ the principle of constructive trust. (Marvin v. Marvin, supra, 18 Cal.3d at p. 684; see Hall v. Hall (1950) 98 Cal. App.2d 209, 212 [219 P.2d 808]; see also Annot. (1981) 3 A.L.R.4th 13, 22-23.) (4) It may even impose a constructive trust to prevent unjust enrichment without a finding of a fiduciary relationship. (Martin v. Kehl (1983) 145 Cal. App.3d 228, 236 [193 Cal. Rptr. 312], italics added; also see Omer v. Omer (1974) 11 Wn.App. 386 [523 P.2d 957], cited in Marvin v. Marvin, supra, 18 Cal.3d at p. 684.)[5] (5) Moreover, a constructive trust may be imposed in practically any situation where there is a wrongful acquisition or detention of property to which another is entitled. (Weiss v. Marcus (1975) 51 Cal. App.3d 590, 600 [124 Cal. Rptr. 297].) (2b) Therefore, appellant need not allege a confidential or fiduciary relationship in order to sufficiently plead that form of equitable relief.
Appellant may also request the trial court to find that a resulting trust arose in her favor on the Lakewood property. (6) "Ordinarily, a resulting trust arises in favor of the payor of the purchase price of the property where the purchase price, or a part thereof, is paid by one person and the title is taken in the name of another. [Citations.]" (Martin v. Kehl, supra, 145 Cal. App.3d at p. 238; see Marvin v. Marvin, supra, 18 Cal.3d at p. 683.) (2c) Although the precise amount and proportion of the consideration furnished by appellant towards the purchase price of the Lakewood property is unknown, appellant should be allowed to amend her complaint to present her version of the facts and to request equitable relief in the form of a resulting trust.
We believe appellant can amend her complaint to plead an action based strictly in equity. Respondent might be unjustly enriched if she were not allowed to do so.


*140 II.

The Four-year Limitation Period of Code of Civil Procedure Section 343 Governs Actions Based Strictly in Equity.
(7) "An action based strictly in equity, as where plaintiff claims an interest in property standing in the defendant's name and acquired during the period of cohabitation and seeks to impose a ... constructive trust, must be brought within four years." (1 Markey, Cal. Family Law Practice and Procedure, § 1.48, p. 1-101, and cases cited within.) (8) "[S]ection 343 of the Code of Civil Procedure providing a four-year statute of limitations applies in `all suits in equity not strictly of concurrent cognizance in law and equity.'" (Pack v. Vartanian (1965) 232 Cal. App.2d 466, 476 [42 Cal. Rptr. 729] [putative wife recovered property from putative husband, court held four year statute of limitations applied].)[6] (9a) In the present case, appellant filed her complaint on September 21, 1981, less than four years after the parties began to live apart. Thus, appellant brought her cause of action within the time prescribed by section 343, which is the relevant statute of limitations.
Respondent argues that appellant's cause of action arises from an implied contract and, therefore, all equitable remedies are merely ancillary to a breach of contract action. We do not agree. The single indicia of "contract" in the complaint is the caption which reads, "Breach of Implied Contract." Significantly, respondent himself cites cases which hold that the nature of the right claimed, not the form of the action, determines the applicability of the statute of limitations. (See Vallera v. Vallera (1944) 64 Cal. App.2d 266 [148 P.2d 694].) (10) "Neither the caption, form, nor prayer of the complaint will be deemed conclusive in determining the nature of the liability from which the cause of action flows. On the contrary, the true nature of the action will be ascertained from the basic facts a posteriori." (Agair Inc. v. Shaeffer (1965) 232 Cal. App.2d 513, 516 [42 Cal. Rptr. 883].) (9b) Although it may have been possible for appellant to set forth facts constituting a cause of action for breach of an implied contract between respondent and herself, she did not do so. Her cause of action sounded in equity.
Respondent's argument that the three-year period of Code of Civil Procedure section 338, subdivision 4, necessarily governs appellant's action is also without merit. Appellant did not, and need not, allege that respondent breached a duty owed her based on a confidential or fiduciary relationship. As respondent points out, such allegations constitute an action for constructive *141 fraud. (Day v. Greene (1963) 59 Cal.2d 404, 411 [29 Cal. Rptr. 785, 380 P.2d 385, 94 A.L.R.2d 802].) Respondent relied on Day v. Greene which holds that where constructive fraud is the gravamen of an action the three-year limitation period prescribed in Code of Civil Procedure section 338, subdivision 4, is applicable. (Ibid.) (11) (See fn. 7) However, the reasoning of that case is relevant only when the action is based on violation of a confidential relationship or a breach of trust. (Ibid.)[7]Day v. Greene does not apply to actions based strictly in equity. (See Markey, supra, pp. 1101.) Therefore, appellant can simply claim an equitable interest in the property which now stands solely in respondent's name and ask the court to impose an equitable trust. Marvin paved the way for the courts to fashion equitable relief when suitable in light of the facts. (18 Cal.3d at p. 684, fn. 25.) The four-year limitation period of Code of Civil Procedure section 343, which applies to such equitable actions, does not bar appellant's action.

III.

The Trial Court Abused Its Discretion in Granting Respondent's Motion for Judgment on the Pleadings Without Allowing Appellant Leave to Amend.
(12) Trial courts are vested with the discretion to allow amendments to pleadings "in furtherance of justice." (Code Civ. Proc., § 473.) "That trial courts are to liberally permit such amendments, at any stage of the proceedings, has been established policy in this state since 1901. [Citations.]" (Hirsa v. Superior Court (1981) 118 Cal. App.3d 486, 488-489 [173 Cal. Rptr. 418], italics in original.) This rule rests on the fundamental policy that "cases should be decided on their merits." (Grudt v. City of Los Angeles (1970) 2 Cal.3d 575, 585 [86 Cal. Rptr. 465, 468 P.2d 825].)
(13) The standard of review for judgment on the pleadings is the same as on judgment following sustaining of a demurrer. (Fosgate v. Gonzales (1980) 107 Cal. App.3d 951, 957 [166 Cal. Rptr. 233].) It may be reversible error to deny leave to amend to correct defects long known to the defendant and raised by him at the time of trial without giving the plaintiff an opportunity to elect to amend or stand on the pleadings. (See 4 Witkin, Cal. Procedure, supra, § 170, p. 2822.) This rule was strongly affirmed in MacIsaac v. Pozzo (1945) 26 Cal.2d 809 [161 Cal. Rptr. 449], where the Supreme Court of California noted that "[t]he granting of the motion without leave to amend would in many cases be an absolute denial of justice, and is directly opposed to the policy of the law that cases should be tried and decided on the merits." (Id., at p. 816.)
*142 (14a) Respondent withheld his objection regarding the statute of limitations until the day of trial. His delay in attacking appellant's defective pleadings earlier by general demurrer is said to be bad practice. (Gallagher v. California Pac. T. & T. Co. (1936) 13 Cal. App.2d 482, 486 [57 P.2d 195].) Under these circumstances, the court's decision to deny appellant an opportunity to amend constitutes an abuse of discretion. (See Galligan v. San Bruno (1982) 132 Cal. App.3d 869, 876 [183 Cal. Rptr. 466]; Moore v. California Minerals etc. Corp. (1953) 115 Cal. App.2d 834 [252 P.2d 1005].)
After the trial court granted respondent's motion, appellant asked the court's leave to amend in order to remove her cause of action from the two-year limitation period for breach of an implied contract. Denial of such relief was an abuse of the trial court's discretion.
In a similar case, the plaintiff was allowed to amend her complaint from a claim seeking one-half the community property to a claim seeking one-half the proceeds of a joint venture. (Vallera v. Vallera, supra, 64 Cal. App.2d at pp. 268, 271-272.) In both complaints the plaintiff asserted the same rights to one-half of the property. The court noted defendant was not prejudiced by the amendment because a change in plaintiff's theory as to the kind of property interest claimed was not fundamental. (Id., at p. 271; see also Sanders v. Magill (1937) 9 Cal.2d 145 [70 P.2d 159]; Reidy v. Collins (1933) 134 Cal. App. 713, 721 [26 P.2d 712].) (15) Moreover, the modern rule is that "an amended complaint relates back to the date of the filing of the original complaint and thus avoids the bar of the statute of limitations so long as recovery in both pleadings is based upon the same general set of facts." (Hirsa v. Superior Court, supra, 118 Cal. App.3d at p. 489; see Wennerholm v. Stanford Univ. Sch. of Med. (1942) 20 Cal.2d 713, 718 [128 P.2d 522, 141 A.L.R. 1358]; Austin v. Massachussetts Bonding & Insurance Co. (1961) 56 Cal.2d 596 [15 Cal. Rptr. 817, 364 P.2d 681].)
(14b) As noted earlier, in this case appellant could more specifically allege facts which demonstrate that equitable relief is required if she is allowed to amend her complaint. Inasmuch as the amendment will be based on the same general set of facts, which are within the knowledge of respondent, he will not be prejudiced by such amendment. (Vallera v. Vallera, supra, 64 Cal. App.2d at p. 271.) In the final analysis, as the court in Vallera noted, "the aims and objects of a trial are and should be to get at the truth." (Id., at p. 272.) Appellant seeks to do no more than sharpen the issues and thus, simplify the task of the trial court.


*143 DISPOSITION
The judgment dismissing appellant's complaint is reversed and the case is remanded to the trial court for proceedings in accordance with this opinion.
Klein, P.J., and Lui, J., concurred.
NOTES
[1]  We are concerned on this appeal only with the allegations in the appellant's first cause of action. The issues of paternity and child support raised in the second cause of action were resolved pursuant to stipulation between the parties and are not subject to this appeal.
[2]  Code of Civil Procedure section 339 defines the time for commencing actions as follows: "Within two years: 1. An action upon a contract, obligation or liability not founded upon an instrument of writing...."
[3]  Code of Civil Procedure section 343 provides: "An action for relief not hereinbefore provided for must be commenced within four years after the cause of action shall have accrued."
[4]  Code of Civil Procedure section 338, subdivision 4, defines the time for commencing actions as follows: "Within three years ... 4. An action for relief on the ground of fraud or mistake...."
[5]  In Omer v. Omer, supra, 11 Wn.App. 386, 391 [523 P.2d 957, 961], absent a finding of fraud or misrepresentation, the court applied a constructive trust where a clear element of unconscionability was evident and where defendant would be unjustly enriched.
[6]  The court in Marvin v. Marvin, supra, 18 Cal.3d 660, 682, removed the distinctions between putatively married spouses and other nonmarried persons.
[7]  There is no presumption that a confidential relationship exists between persons who are not yet married. (See In re Marriage of Dawley (1976) 17 Cal.3d 342, 355 [131 Cal. Rptr. 3, 551 P.2d 323]; Handley v. Handley (1952) 113 Cal. App.2d 280, 285 [248 P.2d 59].)
