title: rails 3.1 active record insert or update
body: <p>I'm new to rails.</p>
  
  <p>Is there an easy way in active record to pass it a hash of data and if the record exists, update it, and if it doesn't, create it?</p>
  
  <pre><code>data = {}
  data["my_id"] = 356345
  data["description"] = "test123"
  
  w = Descriptions.new(data)
  </code></pre>
  
  <p>Ideally if I ran the above it would only ever have 1 record, not multiple records each time I ran it.  </p>