How can I trap the following Oracle error in a rake task? I can trap
most Oracle errors in the website with “@phone.errors.count > 0”, but
in the rake task the task stops before a check can be done.
The rake task used to work before the Oracle DB administrator decided
to put in foreign key, integrity constraints in Oracle.
OCIError: ORA-00001: unique constraint (OWNER.PHONE_NUMBERS_PK)
violated: INSERT INTO phone_numbers