{"width":"100%","published":"2018-05-17 22:14:03","version":"1.0","url":"https://blog.turai.work/entry/20180517/1526562843","author_name":"thr3a","image_url":null,"description":"\u74b0\u5883 Rails 5.1 \u3084\u308a\u305f\u3044\u3053\u3068 \u666e\u901a\u3001Rails\u306eModel\u306fapp/model\u4ee5\u4e0b\u306b\u4e88\u3081\u8a18\u8ff0\u3059\u308b\u304c\u3001\u7279\u6b8a\u306a\u4f8b\u3067\u52d5\u7684\u306b\u751f\u6210\u3055\u305b\u305f\u3044\u5834\u5408 \u6700\u521d\u306f\u30e1\u30bf\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0\u3067\u3044\u3051\u308b\u3084\u308d\u3063\u3066\u601d\u3063\u305f\u3051\u3069\u3001 > mymodel = Class.new(ApplicationRecord) => #<Class:0x007f8e422a3668> (call '#<Class:0x007f8e422a3668>.connection' to establish a connection) > mymodel.establish_connection(dbconfig) RuntimeError: Anon\u2026","provider_url":"https://hatena.blog","type":"rich","blog_title":"\u52d5\u304b\u3056\u308b\u3053\u3068\u30d0\u30b0\u306e\u5982\u3057","author_url":"https://blog.hatena.ne.jp/thr3a/","categories":["rails"],"html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.turai.work%2Fentry%2F20180517%2F1526562843\" title=\"Rails\u306eModel\u3092\u52d5\u7684\u306b\u751f\u6210\u3057\u3066DB\u306b\u63a5\u7d9a\u3059\u308b\u65b9\u6cd5 - \u52d5\u304b\u3056\u308b\u3053\u3068\u30d0\u30b0\u306e\u5982\u3057\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","provider_name":"Hatena Blog","blog_url":"https://blog.turai.work/","height":"190","title":"Rails\u306eModel\u3092\u52d5\u7684\u306b\u751f\u6210\u3057\u3066DB\u306b\u63a5\u7d9a\u3059\u308b\u65b9\u6cd5"}