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.
thanks for the response.
I have “validates_uniqueness_of :phone_number” in the model, and it
worked fine until the DBA got involved.
Now for this error, Oracle just causes the rake task to abort rather
than returning an error.
thanks for the response.
I have “validates_uniqueness_of :phone_number” in the model, and it
worked fine until the DBA got involved.
Now for this error, Oracle just causes the rake task to abort rather
than returning an error.
The DBA is doing exactly what she should be doing, IMHO.
Clean up your data. Stop breaking the foreign key constraints.
The data is fine, and I am not trying to break any foreign key
constraints.
I am getting an error on an insert, all I need to know is how to
capture the error before Oracle aborts the rake task.
Can I request you to respectfully to bow out of this conversion, so
that someone else may try to help?
The data is fine, and I am not trying to break any foreign key
constraints.
I am getting an error on an insert, all I need to know is how to
capture the error before Oracle aborts the rake task.
Can I request you to respectfully to bow out of this conversion, so
that someone else may try to help?
Sure thing. I’m guessing lots of people are dying to assist you with
fixing your broken DBA.