ABC has picked up the back-nine for the mystery dramedy "Castle."

 
That means that viewers will get a full 22-episode second season for "Castle," which stars Nathan Fillion as a mystery writer who gives occasionally unwanted assistance to a group of NYPD detectives, let by Stana Katic.
 
ABC has been in a busy back-nine pickup mode in recent weeks. "Castle" joins "Modern Family," "Cougar Town," "The Middle" and "FlashForward" in earning full season orders. With each gradual pickup, the future gets fuzzier for the ABC shows without the same vote-of-confidence, a group that includes critically savaged comedy "Hank" and new 10 p.m. dramas "Eastwick" and "The Forgotten."
 
"Castle" has been an interesting case for ABC. Blessed with positive (but not rapturous) reviews, "Castle" routinely sheds 7 million viewers from its "Dancing with the Stars" lead-in. Also, despite Fillion's passionate online fanbase, "Castle" has had trouble retaining the 18-49 audience from the already old-skewing "Dancing with the Stars." A similar performance last season had "Castle" very much on the renewal bubble.
 
According to The Hollywood Reporter, recent minor increases in the key demo may have given ABC the confidence necessary for the renewal.