Well, usually (I say usually) many laws make the disclosure of confidential necessary. Often a court may rule or require that confidential information must be provided in order to proceed in a case. For example, if during a murder case, confidential medical records could be used (within the confines of the court) to prove a motive or could be used to identify a killer. In my home country (Australia) I am not sure about this but in the UK if this information involves a child's wellbeing and the pros outweigh the cons then it can be release/used however you will have to be prepared to justify your actions.