I want to force a save of an object even when a validation fails. I tried doing this
te.save(:validate => false)
However, this did not seem to work. What is the right way to do this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
That’s the way according to the source of
save_with_validation.Are you sure it’s not saved? Maybe you have database constraints which keep you from saving your object.
Have you checked your logs looking for INSERTs or UPDATEs?