If you are writing a middle-grade (young adult or picture book, too), I've found Kristi Holl's ebook, "Writing Mysteries for Young People," very helpful. So many books are geared to writing for adults--I'm not murdering anyone in my stories. The essentials of mystery are still here, but the examples are from children's literature.