Generally, I've found that 4-5 weeks from pitching is usually good for the ales I make. Lagers go 2-3 weeks in the primary and then another 4-5 weeks lagering. I have found that my beers improve in the keg for another month or two after kegging, depending on the beer - but I usually don't wait that long to start drinking them. Some specialty types - like belgian wit beers can take a lot longer. Ask about a specific style on this site and you will probably get an answer. You can also google the style and probably come up with a dearth of articles that will help.