Question: what episode of criminal minds do they go to court?
Answer: Tabula Rasa. A suspected serial killer who's been in a coma since 2004 due to an accident when he was arrested wakes up 4 years later, with no memory of his past, not even his name. While he is tried in court, in which Hotch is testifying against him, the rest of the team investigates his past further.