With ActiveRecord as it currently is, you get the same error for 
anything that might go wrong in the database, 
ActiveRecord::InvalidStatement. That's rather undistinctive, considering 
that there are some problems only the database server can recognize, in 
particular violated uniqueness and foreign key constraints.

If specific exceptions for these tow latter error conditions would help 
you in your code, or if you are interested in the topic in general, 
please review the following ticket and patch

https://rails.lighthouseapp.com/projects/8994/tickets/2419-raise-
specific-exceptions-for-violated-database-constraints

Please state your opinion and/or support, for otherwise the issue might 
be delayed interminably.

Thanks,
Michael

-- 
Michael Schuerig
mailto:[email protected]
http://www.schuerig.de/michael/


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to