
365 Mass. 265 (1974)
311 N.E.2d 47
COMMONWEALTH
vs.
CHARLES E. LAMB.
Supreme Judicial Court of Massachusetts, Suffolk.
March 5, 1974.
May 6, 1974.
Present: REARDON, QUIRICO, BRAUCHER, KAPLAN, & WILKINS, JJ.
J. Kevin Leary, Assistant District Attorney, for the Commonwealth.
Francis John Stolarz for the defendant.
REARDON, J.
The defendant argued exceptions in the Appeals Court, alleging errors in the proceedings leading to his commitment as a sexually dangerous person under G.L.c. 123A, § 6. The Appeals Court sustained his exceptions with respect to both the admission of hearsay evidence and the denial of his right to invoke the psychotherapist-patient privilege under G.L.c. 233, § 20B. Commonwealth v. Lamb, Mass. App. Ct. (1973).[a] The Commonwealth's application for further appellate review under G.L.c. 211A, § 11, was granted to be limited to the issue of *266 the applicability vel non of the psychotherapist-patient privilege.
Following prior proceedings, a judge of the Superior Court ordered the defendant committed to the treatment center for the care, custody, treatment and rehabilitation of sexually dangerous persons established under G.L.c. 123A, § 2, for a period not to exceed sixty days for the purpose of examination and diagnosis. On December 15, 1970, the Suffolk County district attorney petitioned the Superior Court to commit the defendant pursuant to c. 123A, § 6. On March 9, 1972, after hearing, a judge of the Superior Court found the defendant to be a sexually dangerous person and committed him to the treatment center for an indeterminate period.
At the hearing on the petition for commitment, the judge heard testimony from Dr. Newman Cohen, a psychiatrist who by order of the court had interviewed the defendant at the treatment center. The defendant attempted to invoke the privilege of G.L.c. 233, § 20B, and requested the judge to instruct the witness not to testify as to the content of any conversations with the defendant. The judge refused this request and, subject to the defendant's exception, permitted Dr. Cohen to testify inter alia that the defendant had admitted to the use of drugs and alcohol.
The sole issue before us is whether the psychotherapist-patient privilege of G.L.c. 233, § 20B, applies to communications between a person under custody at the treatment center under G.L.c. 123A and a psychiatrist appointed to examine him and report to the court. The relevant parts of the privilege statute are recited in the margin.[1] By its terms *267 the privilege covers the communications at issue here. Both parties agree that if the privilege is not to apply, the communications must fall within one of the specified exceptions and in particular in either exception (a) or exception (b). The Commonwealth contends that both (a) and (b) must be applicable to maintain the objectives of G.L.c. 123A (the sexually dangerous persons act). For exception (b) to apply, the patient must have been informed by the psychiatrist that any communication would not be privileged. No such warnings were given in this case. If both exceptions (a) and (b) are relevant, of course, this failure to inform the patient that the communication would not be privileged would be of no consequence since the privilege would be properly denied under exception (a). We agree, however, with the Appeals Court that exception (b) must govern exclusively in these circumstances and that, *268 absent the proper warnings, there can be no departure from the general policy of the statute protecting the confidentiality of communications between a patient and psychotherapist.
For exception (a) to be applicable, one would have to find in this case that Dr. Cohen "in the course of his diagnosis" determined that the defendant was "in need of treatment in a hospital for mental or emotional illness" and that he disclosed the communication "for the purpose of placing or retaining the patient in such hospital." Passing the question noted by the Appeals Court, Mass. App. Ct. at (1973),[b] as to whether the treatment center is to be considered a "hospital" within the meaning of the statute, we believe that the quoted language is intended to apply to a situation in which the patient is not institutionalized or is about to be discharged from an institution. It is not, we think, applicable to the case where the patient is already in the custody of State officials and where there has commenced a deliberate, orderly, judicially-supervised proceeding for determining whether he shall be committed. Exception (a) specifies that the privilege is inapplicable not only when the disclosure is made for the purpose of "placing or retaining" but also when it is made for the purpose of placing the patient under arrest or under the supervision of law enforcement authorities. These three permitted purposes show the Legislature's intention to dispense with the privilege when there is an imminent threat that a person who should be in custody will instead be at large. For any other purpose the privilege is to be maintained. The proviso indicates that after the patient is in a hospital the privilege is ordinarily to continue. We believe that the defendant's situation here was more analogous to the case of a patient in a hospital than it is to the case where a psychiatrist's otherwise privileged testimony is necessary "to place or retain" a patient in a hospital.
Perhaps more significantly, reading the statute as a whole, we are convinced that a construction which deems a *269 court-ordered interview between a psychotherapist and a patient under G.L.c. 123A to be within the exclusive ambit of exception (b) yields a more effectual and harmonious piece of legislation. See Mathewson v. Contributory Retirement Appeal Bd. 335 Mass. 610, 614-615 (1957). The policy of exception (b) is to permit a court to utilize expert psychiatric evidence by ordering an examination. In that situation, however, the statute recognizes that such court-initiated interviews entail certain risks for the person to be examined. It provides the procedural protection that notice is to be given if the privilege is not to apply in those circumstances. This protection seems particularly suitable for cases such as this where the patient runs the risk of commitment as a sexually dangerous person depending on what he says in an interview which in the normal course of affairs would be accorded confidentiality. If we were to hold that this protection was denied patients because psychiatric examinations under G.L.c. 123A also were covered by exception (a), we would render nugatory the important policy objective of the statute evinced by the notice requirement in exception (b). Such an interpretation is to be avoided. See Selectmen of Topsfield v. State Racing Commn. 324 Mass. 309, 312-314 (1949).
Moreover, by interpreting the statute to preserve the privilege in the circumstances being considered, we are able to avoid a construction which raises substantial constitutional questions on the procedures prescribed by G.L.c. 123A. "We must construe the statute, `if fairly possible, so as to avoid not only the conclusion that it is unconstitutional but also grave doubts upon that score.'" Board of Appeals of Hanover v. Housing Appeals Comm. in the Dept. of Community Affairs, 363 Mass. 339, 364 (1973), quoting United States ex rel. Attorney Gen. of U.S. v. Delaware & Hudson Co. 213 U.S. 366, 408 (1909). The procedures which constitutionally must be accorded one who is the subject of a proceeding under G.L.c. 123A are not identical to those required for persons accused of crimes since G.L.c. 123A proceedings are civil and nonpunitive in nature. Commonwealth v. Hogan, 341 Mass. 372, 376 (1960). Commonwealth v. Ackers, 343 Mass. 63, 68 (1961). *270 Nevertheless such persons are plainly entitled to certain minimum standards of procedural due process. Commonwealth v. Gomes, 355 Mass. 479, 484 (1969). In certain circumstances it has been assumed that one in custody prior to the commencement of proceedings under c. 123A has rights under the Fifth Amendment including the right to receive the warnings articulated in Miranda v. Arizona, 384 U.S. 436 (1966). Commonwealth v. Cain, 361 Mass. 224 (1972). The question of which procedural safeguards are constitutionally required in commitment proceedings under G.L.c. 123A is currently undergoing a thorough reexamination. Compare Commonwealth v. McGruder, 348 Mass. 712 (1965), cert. den. sub nom. McGruder v. Massachusetts, 383 U.S. 972 (1966), with Commonwealth v. Bladsa, 362 Mass. 539 (1972). Compare Commonwealth v. Gomes, 355 Mass. 479 (1969), with Sarzen v. Gaughan, 489 F.2d 1076, 1082-1086 (1st Cir.1973). We construe G.L.c. 233, § 20B, as preserving a patient's rights to keep privileged any communications made to a court-appointed psychotherapist in the case of a court-ordered examination, absent a showing that he was informed that the communication would not be privileged and thus, inferentially, that it would be used at the commitment hearing. In so doing we avoid considering whether the use of such statements in the absence of such warnings infringes upon the rights of due process guaranteed by the Fourteenth Amendment of the United States Constitution.
The Commonwealth contends that such an interpretation would eliminate the ability of the psychiatrist to provide specific information which might be critical to a judge's determination at the hearing. We do not agree. Exception (b) is directed to exactly the opposite result. As prerequisite to its use, however, the patient will have to be informed that the statement is not privileged. We believe it is this balance between the need for fairness and disclosure to the patient and full information for the court which the Legislature intended to strike.
The exception relating to the psychotherapist-patient *271 privilege is sustained, and the case is remanded to the Superior Court.
So ordered.
NOTES
[a]  303 N.E.2d 122.
[1]  Section 20B, inserted by St. 1968, c. 418. "The following words as used in this section shall have the following meanings: 

"`Patient', a person who, during the course of diagnosis or treatment, communicates with a psychotherapist;
"`Psychotherapist', a person licensed to practice medicine who devotes a substantial portion of his time to the practice of psychiatry; and
"`Communications' includes conversations, correspondence, actions and occurrences relating to diagnosis or treatment before, during or after institutionalization, regardless of the patient's awareness of such conversations, correspondence, actions and occurrences, and any records, memoranda or notes of the foregoing.
"Except as hereinafter provided, in any court proceeding and in any proceeding preliminary thereto and in legislative and administrative proceedings, a patient shall have the privilege of refusing to disclose, and of preventing a witness from disclosing, any communication, wherever made, between said patient and a psychotherapist relative to the diagnosis or treatment of the patient's mental or emotional condition.
"If a patient is incompetent to exercise or waive such privilege, a guardian shall be appointed to act in his behalf under this section. A previously appointed guardian shall be authorized to so act.
"Upon the exercise of the privilege granted by this section, the judge or presiding officer shall instruct the jury that no adverse inference may be drawn therefrom.
"The privilege granted hereunder shall not apply to any of the following communications: 
"(a) If a psychotherapist, in the course of his diagnosis or treatment of the patient, determines that the patient is in need of treatment in a hospital for mental or emotional illness or that there is a threat of imminently dangerous activity by the patient against himself or another person, and on the basis of such determination discloses such communication either for the purpose of placing or retaining the patient in such hospital, provided however that the provisions of this section shall continue in effect after the patient is in said hospital, or placing the patient under arrest or under the supervision of law enforcement authorities.
"(b) If a judge finds that the patient, after having been informed that the communications would not be privileged, has made communications to a psychotherapist in the course of a psychiatric examination ordered by the court, provided that such communications shall be admissible only on issues involving the patient's mental or emotional condition but not as a confession or admission of guilt."
[b]  303 N.E.2d at 125.
