Come to think of it, most of the cop/detective shows I like involve main characters who are not actually cops/detectives (Monk - he's a former cop; Psych - he's the son of a cop; Fringe - FBI agent + mad scientist & son; Numbers - the professor is the brother of an FBI agent; The Mentalist - he's a former psychic entertainer). Hmmm - that's a topic for another day, perhaps.
Anyway, I mention Castle because of an interesting literary tie-in. It turns out the fictional author Richard Castle (played by Nathan Fillion) has published a real book: Heat Wave. The book is featured in the show, and is also available at fine bookstores everywhere. I haven't read it yet, and I don't know who actually wrote it, but it looks pretty interesting and is getting some good reviews.
I just think it's cool that they broke the fourth wall in such an original and literal way.