You should look into Aaron Walls "SEO Book" to start and If you really want to do it yourself look at attending some classes and seminars.

There is two tricks to this industry. Knowing the technical jargon (on page optimization) and having contacts in the link building industry (off page). The latter is much harder to build.