{"height":"190","image_url":null,"url":"https://kwatch.hatenadiary.org/entry/20081204/1228404214","provider_name":"Hatena Blog","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fkwatch.hatenadiary.org%2Fentry%2F20081204%2F1228404214\" title=\" DataMapper \u3067\u306e\u4e00\u610f\u5236\u7d04\u306e\u6307\u5b9a\u65b9\u6cd5 - k\u306a\u3093\u3068\u304b\u306e\u65e5\u8a18\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","author_url":"https://blog.hatena.ne.jp/kwatch/","type":"rich","width":"100%","blog_title":"k\u306a\u3093\u3068\u304b\u306e\u65e5\u8a18","published":"2008-12-04 00:23:34","categories":["merb"],"provider_url":"https://hatena.blog","description":"DataMapper \u3067\u4e00\u610f\u5236\u7d04 (unique constraint) \u3092\u3064\u3051\u308b\u65b9\u6cd5\u304c\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u306b\u898b\u3064\u304b\u3089\u306a\u3044\u3068\u601d\u3063\u305f\u4eba\u306f\u304a\u3089\u3093\u304b\u30fc\uff1f DataMapper \u3067\u306f\u3001\u4e00\u610f\u5236\u7d04\u306b\u306f :unique_index \u30aa\u30d7\u30b7\u30e7\u30f3\u3092\u3064\u3051\u308c\u3070\u3088\u3044\u3002 class Department include DataMapper::Resource property :id, Serial ## \u5358\u4e00\u30d7\u30ed\u30d1\u30c6\u30a3\u306b\u4e00\u610f\u5236\u7d04\u3092\u3064\u3051\u305f\u3044\u3068\u304d property :name, String, :nullable=>false, :unique_index=>true ## \u8907\u6570\u306e\u30d7\u30ed\u30d1\u30c6\u30a3\u306b\u307e\u305f\u304c\u3063\u3066\u4e00\u610f\u5236\u7d04\u3092\u3064\u3051\u305f\u3044\u3068\u304d \u2026","author_name":"kwatch","version":"1.0","title":" DataMapper \u3067\u306e\u4e00\u610f\u5236\u7d04\u306e\u6307\u5b9a\u65b9\u6cd5","blog_url":"https://kwatch.hatenadiary.org/"}