Rails force an object to be saved even when validation fails

I want to force an object to be saved even if validation fails. I tried to do it

te.save(:validate => false)

However, this did not seem to work. What is the right way to do this?

+3
source share
1 answer

This is the path according to the source save_with_validation.

Are you sure this is not saved? Perhaps you have database restrictions that prevent you from storing your object.

Have you checked your logs for INSERT or UPDATE?

+4
source

All Articles