<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>woshidan</author_name>
  <author_url>https://blog.hatena.ne.jp/woshidan/</author_url>
  <blog_title>woshidan's blog</blog_title>
  <blog_url>https://woshidan.hatenablog.com/</blog_url>
  <categories>
    <anon>Rails</anon>
    <anon>ActiveRecord</anon>
  </categories>
  <description>たまたま仕事で気になったので、ActiveRecord::Baseのcreateとsaveの違いについて簡単に調べました。 まとめ save(!)メソッドはcreate(!)メソッドで利用されている create(!)メソッドはnewメソッドとsave(!)メソッドを行うメソッド save(!)メソッドを利用しているので、レコードの保存に失敗した場合、createメソッドでは属性が代入されたオブジェクトが返り、create!メソッドでは例外が発生する save(!)メソッドの中を追っていくと、new_record?メソッドの返り値によって、INSERT文を呼び出しているメソッドとUPDATE文…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fwoshidan.hatenablog.com%2Fentry%2F2015%2F09%2F29%2F224750&quot; title=&quot;ActiveRecord::Baseのcreateとsaveの違い - woshidan&amp;#39;s blog&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2015-09-29 22:47:50</published>
  <title>ActiveRecord::Baseのcreateとsaveの違い</title>
  <type>rich</type>
  <url>https://woshidan.hatenablog.com/entry/2015/09/29/224750</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
