<P> "Death and All His Friends" is the season finale of the sixth season of the American television medical drama Grey's Anatomy, and the show's 126th episode overall . It was written by Shonda Rhimes and directed by Rob Corn . The episode was originally broadcast on the American Broadcasting Company (ABC) in the United States on May 20, 2010 . The episode was the second part of the two - hour season six finale, the first being Sanctuary, and took place at the fictional Seattle Grace Hospital . The original episode broadcast in the United States had an audience of 16.13 million viewers and opened up to universal acclaim . The episode centers a shooting spree at the hospital by a former patient's husband Gary Clark (Michael O'Neill). The episode marked the last appearances for Nora Zehetner and Robert Baker as Dr. Reed Adamson and Dr. Charles Percy respectively as both the characters were killed in the shooting . </P> <P> In the episode Cristina Yang (Sandra Oh) and Jackson Avery (Jesse Williams) try to save the life of Chief Derek Shepherd (Patrick Dempsey) who was shot by Gary Clark in front of Meredith Grey (Ellen Pompeo) as she waits outside the OR with April Kepner (Sarah Drew). Miranda Bailey (Chandra Wilson) tries to save Charles along with her patient Mary Portman (Mandy Moore), while Richard Webber (James Pickens, Jr .) tries to get into the hospital . Callie Torres (Sara Ramirez) and Arizona Robbins (Jessica Capshaw) are stuck on a floor with all the younger patients of the hospital, Mark Sloan (Eric Dane) and Lexie Grey (Chyler Leigh) try to save the life of Alex Karev (Justin Chambers) who was shot as well and Owen Hunt (Kevin McKidd) and Teddy Altman (Kim Raver) try to get their patient to safety . </P> <P> The hospital is hit with an unprecedented crisis: a shooter is in the hospital, and there is a lockdown . Meanwhile, Dr. Meredith Grey (Ellen Pompeo) discovers that she is pregnant, and Dr. Owen Hunt (Kevin McKidd) must choose between Teddy and Cristina (Sandra Oh). The shooter kills Reed Adamson and wounds Dr. Alex Karev (Justin Chambers). Lexie (Chyler Leigh) and Mark (Eric Dane) find the latter and try to save him . Soon, it is revealed that the shooter, Gary Clark (whose wife was a patient at the hospital and later died), is looking for Dr. Derek Shepherd (Patrick Dempsey). At the end, he shoots Derek, which is witnessed by Meredith, Cristina, and April . With the crisis unfolding, each character is put through extreme trials and tribulations . Cristina is put under pressure to save Derek, who is seriously injured . </P> <P> Meanwhile, Dr. Miranda Bailey (Chandra Wilson) and her patient Mary drag intern Charles Percy, who has been shot, through the hallway but when they get to the elevators, they are off . Bailey freaks out for a moment, then gathers herself and sits with Charles . When he asks if he was dying, she said yes . She tells him she and Mary are going to stay with him and that he isn't alone, with Charles dying soon thereafter . The shooter walks into the OR where Cristina and Jackson are trying to save Derek . Hunt shows up and Meredith tells him what was going on . He looks through the window and says she is doing fine but he'd go in to see what he could do to help . When Hunt goes inside, the audience is shown that Mr. Clark is in the room with a gun to Cristina's head, shouting at her to stop fixing Derek . Cristina and Avery refuse to stop working . </P>

When does derek get shot in grey's anatomy
find me the text answering this question