Check out this blog post: http://blog.remarkablelabs.com/2012/12/a-love-affair-with-po...
When I first got to Rails it seemed that databases were considered as a bothersome but unavoidable necessity; flat files with a funny accent, instead of an essential and powerful ally in the fight against entropy and error.
Some poking around in the current documentation seems to suggest that FKs have been absorbed into ActiveRecord.
Interesting link, either way.
As much as I like Rails, I sometimes wish it were designed with the database playing more of a role than just dumb storage. Defining things like validations in Ruby is certainly nice and easy, but the database is much better suited to actually enforcing such constraints.
In your webapp using POSTGRESQL, are you actually using SQL statements in your code to retrieve the data? Or is there some other way to get at it?
Rather than me explaining it here, the rails guides[1] give you a good overview.
[1] http://guides.rubyonrails.org/active_record_querying.html