I''m experimenting with RoR and am stuck on the following problem. I have a table called Connections. Connections belong to a Network and have a name and destination. I am using Ruby''s single table inheritance as there are different types of connections (Http connections require a url, LU 6.2 connections require LU names, etc). The Connection names must be unique for the Network: name and network_id must be unique (this is enforced by the DBMS). My models for Connection, Http, Lu62 look like: class Connection < ActiveRecord::Base belongs_to :network validates_uniqueness_of :name, :scope => "network_id" validates_presence_of :destination end class Http < Connection validates_presence_of :http_url end class Lu62 < Connection validates_presence_of :lu_name end The problem is that the validates_uniqueness_of only seems to work for connections of the same type. It catches attempts to insert a duplicate name-network_id when the two connections are Http, but fails if the duplicate is of a different type (Lu62). Am I doing something wrong? Thanks, Dan