title: How to get id values after saving an ActiveRecord model in rails
body: <p>I have an ActiveRecord model (I'm on rails 2.3.8) called user and I'm saving it as </p>
  
  <pre><code>user = User.new
  user.name = "user name"
  user.save!
  </code></pre>
  
  <p>what I want to do is get the generated user id after creating the user. But currently it returns true/ false value upon saving</p>
  
  <p>How can I get the saved user id?</p>