Guaranteeing uniqueness and persistence with ActiveRecord
Generally, when someone wants to ensure that a models field is unique, they use a database unique index in conjunction with validates_uniqueness_of :field. The problem with this approach…
Generally, when someone wants to ensure that a models field is unique, they use a database unique index in conjunction with validates_uniqueness_of :field. The problem with this approach…