haha, that's really interesting to hear. I'm almost certain a Judge is also not allowed access to medical records. He most likely is not a covered entity. Beyond that while it might make sense to request medical records in a criminal trial, there's no place for that in a civil suit.
HIPAA allows health care providers to disclose medical records in response to a court order as long as the order specifies the scope of the records required to be disclosed and is signed by a judge.