second example from http://ruby.railstutorial.org/book/ruby-on-rails-tutorial# with pg not sqlite