
229 Cal.App.3d 475 (1991)
280 Cal. Rptr. 74
In re RUTH M. et al., Persons Coming Under the Juvenile Court Law.
SAN DIEGO COUNTY DEPARTMENT OF SOCIAL SERVICES, Plaintiff and Respondent,
v.
INES N., Defendant and Appellant.
Docket No. D011451.
Court of Appeals of California, Fourth District, Division One.
April 17, 1991.
*477 COUNSEL
Kenneth H. Stone and Gary S. Plavnick, under appointments by the Court of Appeal, for Defendant and Appellant.
*478 Lloyd M. Harmon, Jr., County Counsel, Susan Strom, Chief Deputy County Counsel, and Patrice D. Plattner, Deputy County Counsel, for Plaintiff and Respondent.
Sandra Bennewitz, under appointment by the Court of Appeal, for Minors.
[Opinion certified for partial publication.[1]]
OPINION
HUFFMAN, Acting P.J.
This is an appeal from a permanency planning order made by the juvenile court pursuant to Welfare and Institutions Code section 366.25[2] regarding the four children of appellant Ines N. (Mother). Ruth M., the oldest of the four children, was placed in long-term foster care in one foster home, and Betzel M. (Betsy), Thomas M., and Maria M. (collectively, the three younger children) were placed in long-term foster care together in another foster home. Mother contends the juvenile court prejudicially erred when it refused to relieve her court-appointed attorney from representing her before the contested permanency planning hearing. Mother also attacks the permanency planning order on several other grounds: it was made too soon after the juvenile court last removed the children from Mother's home, there was no express finding that reasonable reunification services had been provided, and the order is not supported by sufficient evidence. None of these contentions has merit. We affirm the order.

I

FACTUAL AND PROCEDURAL BACKGROUND

A. Procedural History Leading to the Permanency Planning Hearing

These four children were born to Mother and her former husband (who is now deceased or missing) in 1972, 1974, 1976, and 1977. From December 1984 through April 1987, all four children were brought under the jurisdiction of the juvenile courts of Stanislaus and Riverside Counties and placed in foster care by reason of Mother's mental illness. (§ 300, subd. (a).) They were returned to Mother's custody in April 1987, but were again declared dependents of the juvenile court and placed in foster care in Riverside County proceedings in September and October 1987.
*479 Mother moved to San Diego County in April 1988 and began living with Ray N., whom she married in December 1988. Ray had a chronic disability and was being treated at the Veterans Administration hospital. The children were placed with Mother on a trial basis in September 1988, and jurisdiction was transferred to the juvenile court of San Diego County in November 1988.
Ruth began individual and family therapy in January 1989, with some prospects of success in resolving her family problems. However, she became increasingly depressed and anxious, had serious learning problems in school, and talked of suicide in March 1989 to escape from living with her mother and stepfather. Her therapist recommended out-of-home placement to Ruth's social worker, and Mother and Ray agreed. A supplemental petition was filed pursuant to section 387 to remove her from the home and was found true by the court on April 4, 1989. Ruth was placed in foster care on May 10, 1989, and Mother was ordered to comply with a reunification plan.
On June 8, 1989, Mother "ran away from home," as Maria later put it in her therapy. Mother left the three younger children in Ray's care, and left him a note saying that although she loved him and the children, she had to leave because of too much pressure and stress from the children. She said she was sick, in crisis, and needed some time alone. Ray N. called the children's social worker, said he was not physically able to take care of the children, and asked that she take them into custody.[3] She did so, placing the children at a shelter and filing a supplemental petition pursuant to section 387 stating there were no responsible adults to care for the children.
Mother was noticed of but did not appear at the dispositional hearing on the petition concerning the three younger children, held July 12, 1989. The juvenile court took jurisdiction by default, removed the three children from Mother's custody (§ 361, subd. (b)), and placed them in foster care. A reunification plan was ordered, requiring many standard elements, parenting education, and an ability to show Mother could provide adequate child care so the children would not be left unsupervised again.
Mother's compliance with the two reunification plans was incomplete, as she had not completed parenting class or support group work and had *480 visited only sporadically. Accordingly, the social worker's recommendation at the time of the permanency plan proceedings, taking the children's wishes into account, was to keep them in their current foster home placements. At Mother's request, the matter was set for a contested hearing on December 19, 1989, as to all four children.
At the permanency planning hearing, social studies for the four children were submitted to the court. The court made findings that return of all the minors to Mother's custody would create a substantial risk of detriment to their physical or emotional well-being, and there was no substantial probability the minors could be returned in six months. The children were found not to be adoptable because of their ages. Long-term foster care was ordered, court-mandated reunification services were terminated, and a review date was set. (1, 2) (See fn. 4.) Mother appeals the order.[4]

B. Background Facts[*]
.... .... .... .... .... .

II

DISCUSSION
In reviewing the validity of the permanency planning order, we first inquire whether the juvenile court committed prejudicial error by denying the requests of Mother and her counsel to remove him from representing her in these proceedings. We then turn to Mother's specific attacks on the order, its timing and the sufficiency of the findings and evidence in support of it.[7]

A. Mother's Motion to Relieve Her Attorney[*]
.... .... .... .... .... .


*481 B. Timing of the Permanency Planning Hearing Under Section 366.25, Subdivision (a).

(3a) In her first attack upon the validity of the permanency planning order, Mother focuses upon the language of section 366.25, subdivision (a)[10] to argue that the permanency planning hearing was held too soon after the most recent placements of Ruth and the three younger children in her home. Specifically, she points out the provisions in that section for a lapse of 12 months between the "original dispositional hearing in which the child was removed from the custody of his or her parent, ..." and the permanency planning hearing date, and the alternative provision for a lapse of no more than 18 months before that hearing date from "the time of the minor's original placement pursuant to Section 319 [concerning the original detention] or 16507.4 [concerning the provision of voluntary family reunification services]."[11] Mother thus argues that since the permanency planning hearing was held only eight months after the end of Ruth's most recent home placement, and only six months after the end of the three younger children's most recent placement with her, the statutory requirements of section 366.25, subdivision (a) were not met. In short, Mother contends her children were with her for substantial periods during their dependencies and her family situation is thus covered by section 366.25, subdivision (f): "Physical custody of a minor by his or her parents or guardians for insubstantial periods during the 12-month period prior to a permanency planning hearing shall not serve to interrupt the running of those periods."
To analyze Mother's argument, we must look at these facts in light of the statutory language and legislative intent of section 366.25. Examining the closely parallel factual context of Civil Code section 232 termination of parental rights proceedings is instructive. In In re Connie M. (1986) 176 Cal. App.3d 1225 [222 Cal. Rptr. 673], a termination of parental rights proceeding, the record showed the child had been placed with the natural parents for eight months on a trial basis after living for three years with *482 foster parents. After the trial placement did not work out and the foster parents sought adoption of the child, the court held the requisite one-year period of foster care under Civil Code section 232, subdivision (a)(7)[12] could occur at any time before the filing of the petition and did not have to occur during the year which immediately preceded the filing. (In re Connie M., supra, 176 Cal. App.3d at pp. 1237-1240.) The court rejected the mother's arguments that the one-year period immediately prior to termination of her rights was the critical period for judging her ability to care for the child. (Id. at p. 1239.) Instead, the court stated the overall legislative purpose of the statute should control: serving and protecting the best interests and welfare of the child. (Ibid.) These goals were best served by allowing and encouraging such trial placements with parents, without requiring that the applicable statutory period (i.e., before termination proceedings) start to run anew with each trial placement.[13]
(4) It is evident from the language of section 366.25, subdivision (a) that the same goals of providing "stable, permanent homes for children" (ibid.) are operative in section 300 dependency proceedings as they are in Civil Code section 232 termination proceedings. However, while termination proceedings are geared toward promoting adoption or guardianship by a permanent caretaker, in some dependency proceedings (such as this one) the best available alternative appears to be long-term foster care. (See In re Emily L. (1989) 212 Cal. App.3d 734, 742 [260 Cal. Rptr. 810].) Such foster care can provide the stability and permanency in a home that would otherwise be lacking in a dependent child's life. The juvenile court in its discretion is best equipped to decide in each individual case the available avenue most likely to lead to stability and permanency in these children's lives. In interpreting section 366.25, subdivisions (a) and (f), such discretion must be exercised in accordance with the stated statutory purpose.
Turning to the particular facts of this case, Mother attempts to distinguish the reasoning of Connie M. (supra, 176 Cal. App.3d 1225) on the basis *483 that these minors are not adoptable (as was Connie M.). Nevertheless, as we have discussed above, under these circumstances long-term foster care appeared to be the functional equivalent of adoption, in lieu of any other available alternative.
Mother also claims that Connie M. should not control because the September 1988 placement with her was anticipated to be permanent, since a new section 387 petition was later required to reactivate the dependency. This argument, however, ignores the distinction between a supplemental petition under section 387, such as was used here, and an initial dependency petition to establish jurisdiction brought under section 300. These children had been under uninterrupted dependency jurisdiction since October 1987, when the Riverside court sustained a section 300 petition. The transfer to San Diego County in November 1988 in no way interrupted the dependency jurisdiction, nor did the filing of the two supplemental petitions pursuant to section 387.
(3b) Accordingly, for purposes of applying section 366.25, subdivision (a), the date from which the 12-month period before the permanency planning hearing date ran was the October 1987 dispositional hearing in Riverside County; the date from which the 18-month period ran was the original detention of the children in those proceedings (either September or October 1987; the record is unclear on this minor point). Thus, it is clear sufficient time elapsed before this hearing was calendared.[14]
Moreover, at the permanency planning hearing held some two and one-quarter years into the process, the juvenile court was justified in concluding under section 366.25, subdivision (f) that these placements with Mother on a "trial basis" (from September 1988 through April 1989 (about eight months for Ruth) and through June 1989 (about ten months for the three younger children)) were for "insubstantial periods."[15] In making its ruling, the juvenile court was entitled in its discretion to take into account to a limited extent the record showing the previous dependency that was in effect from 1984 through 1987, even though technically these October 1987 proceedings were petitioned separately and were distinct. The social studies before the court at the permanency planning hearing contained information about the earlier case, and it was in the best interests of the children that the *484 court have a full acquaintance with their history in ruling on the petitions concerning them. (See In re Malinda S. (1990) 51 Cal.3d 368, 382-385 [272 Cal. Rptr. 787, 795 P.2d 1244] for discussion of the due process considerations in such use of the social studies.)[16] Thus, Mother has no statutory or theoretical basis to justify selecting the most recent home placement dates from which to measure the 12- or 18-month periods.
(5) Although we have found that the juvenile court, in light of the lengthy background of this case (dating from October 1987 and before), was justified in holding the permanency planning hearing within eight months of the end of Ruth's most recent placement with Mother and within six months of the end of the three younger children's most recent placement with her, we wish to express a note of caution for the sound exercise of discretion of the juvenile court in applying section 366.25. As the court in Connie M., supra, 176 Cal. App.3d 1225, 1239-1241 emphasized, the legislative purpose of this type of statutory scheme is to "achieve the ultimate goal of giving permanency and stability to a child's life as expeditiously and as fairly as possible." (Id. at p. 1241.) In calculating the 12- to 18-month period required by section 366.25, subdivision (a) before a permanency planning hearing may be held, the court must correctly apply the "insubstantial periods" test of subdivision (f). Where a child's interest in permanency and stability will best be served by a trial placement with a parent, the proper exercise of the juvenile court's discretion may require a liberal interpretation of the "insubstantial periods" test of subdivision (f). In other words, although in this case, the trial placements for 8 and 10 months were correctly evaluated to be insubstantial, in another factual context they might be very significant and might serve to interrupt the running of the 12-month period.[17]
In evaluating the substantiality of such periods, the juvenile court must exercise its discretion with a view to finding the best solution to a child's problems that is possible under all the circumstances, including any appropriate "last ditch attempts" (In re Connie M., supra, 176 Cal. App.3d at p. 1239) to reunite a family. Flexibility in interpretation of section 366.25, subdivisions (a) or (f) is necessary to serve the best interests of an individual dependent child.
*485 C., D.[*]
.... .... .... .... .... .

DISPOSITION
The order is affirmed.
Froehlich, J., and Nares, J., concurred.
NOTES
[1]  Pursuant to California Rules of Court, rule 976.1, this opinion is certified for partial publication with the exception of parts IB and IIA, IIC and IID.
[2]  All statutory references are to the Welfare and Institutions Code unless otherwise specified.
[3]  Ray and Mother later told her counsel and the special advocate whom the juvenile court appointed to investigate the case that Ray had only requested assistance, not removal of the children from the home. Mother later had a major dispute with her court-appointed counsel about what Ray had really said to the social worker, and would not speak to her counsel in part because of this problem, leading to the Marsden motion (People v. Marsden (1970) 2 Cal.3d 118 [84 Cal. Rptr. 156, 465 P.2d 44]) that was ultimately made and denied.
[4]  Pursuant to section 366.25, subdivision (j), an appeal from a permanency planning order that authorizes the filing of a parental termination action or initiation of a guardianship proceeding is precluded; however, other orders made at a permanency planning hearing, such as placement of a child in long-term foster care, remain appealable. (In re Corienna G. (1989) 213 Cal. App.3d 73, 77-78 [261 Cal. Rptr. 462].)

Ruth reached the age of 18 in November 1990, during the pendency of this appeal. However, it is necessary for this court to review the order as it affects the rights of the parties as of the time it was made; the appeal is not moot. (See § 303, providing the juvenile court may retain jurisdiction over a dependent child until she reaches the age of 21 years.)
[*]   See footnote 1, ante, page 475.
[7]  Counsel for the minors on appeal has filed a letter brief joining in Mother's arguments.
[*]  Section 366.25, subdivision (a) in pertinent part reads as follows: "In order to provide stable, permanent homes for children, a court shall, if the minor cannot be returned home pursuant to subdivision (e) of Section 366.2, conduct a hearing to make a determination regarding the future status of the minor no later than 12 months after the original dispositional hearing in which the child was removed from the custody of his or her parent, parents, or guardians, and in no case later than 18 months from the time of the minor's original placement pursuant to Section 319 or 16507.4...." (Italics added.)
[10]  Section 366.25, subdivision (a) also provides a "fast track" for permanency planning under the circumstances described in section 361.5, subdivision (b) (where no reunification services are deemed appropriate). (See Brandt, 2 Cal. Juvenile Court Practice (Cont.Ed.Bar. Supp. 1990) § 16.1, p. 32.) This was not the case here. Also see California Rules of Court, rules 1461(a), (b)(1) and 1462(a)(1).
[11]  The court in Connie M. was interpreting Civil Code section 232, subdivision (a)(7), which provides for termination of parental rights for a child who has been in foster care for 12 months, where certain findings are made. The section further provides: "Physical custody of the child by the parent or parents for insubstantial periods of time during the required 12-month period will not serve to interrupt the running of such period." (In re Connie M., supra, 176 Cal. App.3d 1225, 1234.)
[12]  In Connie M. the court explained its reasoning as follows: "An additional year in limbo would defeat the compelling state interest of prompt severance of the parental relationship to avoid lasting psychological harm to the child. (In re David B. (1979) 91 Cal. App.3d 184, 195-196 [154 Cal. Rptr. 63].) When reunification efforts fail, the best interests of the child will be served by freeing her from parental control for adoption so that the child may benefit from the prospect of a home which provides stability and security that would otherwise be missing in her life. (In re Eugene W. (1972) 29 Cal. App.3d 623, 629 [105 Cal. Rptr. 736].) An interpretation of the statute as the mother suggests would defeat these compelling interests." (In re Connie M., supra, 176 Cal. App.3d 1225, 1240; see also In re Mary M. (1986) 180 Cal. App.3d 1058 [226 Cal. Rptr. 5].)
[13]  In fact, it appears the December 1989 permanency planning hearing was held some seven months beyond the eighteen-month period of section 366.25, subdivision (a), when counting the time from October 1987.
[14]  On a related point, see In re Michael S. (1987) 188 Cal. App.3d 1448, 1462 [234 Cal. Rptr. 84], where the court stated that a parent's regainment of physical custody during the 12-month period of section 366.25, subdivision (a) (governing the provision of reunification services) did not interrupt the running of the statutory period, where dependency status was not terminated and reunification orders were still in effect.
[15]  Mother had a statutory remedy under section 388 (petition based on changed circumstances) to challenge the order for long-term foster care, but the record does not show she followed such a procedure. However, we disagree with the department of social services' suggestion in its brief that this appeal is perforce frivolous because of Mother's failure to pursue this remedy in the juvenile court.
[16]  Also see In re Mary M., supra, 180 Cal. App.3d 1058, 1064, where a three-month interruption of a two-year period was found to be insubstantial under Civil Code section 232, subdivision (a)(7).
