When it comes to live-action TV shows, Law & Order is the longest running drama of all time, having been on the air for 16 years.
There's something about detectives and murder and mystery, because when it comes to anime, one show has more episodes and movies than any other. Despite populare belief, that show is not Dragonball/Z/GT.
That show is called...

Detective Conan (Case Closed in U.S.) has over 700+ episodes and is STILL ongoing in Japan. It also has several movies and TV specials and with DB/Z/GT only being just under 400, this one has it -- and everything else -- beaten.
Detective Conan is the story of a seventeen year old wonder student named Shinichi Kudou. Though only a high-school senior, Shinichi is the best detective in town; much better than the police (who often turn to him for help) and Kogorou Mouri, who is also a Private Detective and his best-friend, would-be-girlfriend's father. Kogorou hates Shinichi, but Mouri Ran, his daughter, is only a few kind words away from dating him.
Unfortunately, after solving a decapitation on a roller coaster which he and Ran happen to witness, Shinichi pokes his nose into the business of two men in black coats who call themselves "Gin" and "Vodka". They force him some new, experimental posion that's supposed to kill and make it seem natural on a toxicology report. Unfortunately that's not what happens. Shinichi wakes up... as a seven year old boy!
Now, using the name Edogawa Conan, he's living with Ran and her father, and using the inventions of his next door neighbor, a genius scientist, to help Kogouro solve crimes so that maybe he can get a lead on who gave him the drugs and find a antidote.
It's hilarious at times, and a VERY good mystery show. I like it. :D Except the story moves HORRIBLY SLOW -- 700+ episodes, and I'd say 680 of them are filler. ;_; Oh well!