Are there any performance/other implications in having an object relates to itself? (self join)
Consider the following example:
PEOPLE (table name)
belongs_to :profile, :class_name => 'Person', :dependent => :destroy
id
login
password
first_name
last_name
profile_id
This question is party stemmed from another question posted at Database Design Related
You don’t specify which database you are using, but AFAIK, not only will there not be any performance problems with self joins, there may be performance benefits over some alternative solutions.
Apart from that, IMHO it is easier to understand than say nested SQL statements, but that is entirely subjective.
See:
http://databases.about.com/od/sql/a/selfjoin.htm